Week 5 Net Flashcards
What are regular expressions used for?
- match a pattern of characters
- specify pattern to be matched
Steps for making regular expressions in Java?
- create a regular expression as a string
- use pattern to compile regex
- use matcher to apply pattern to a string / input
“\d{2,5} what regex does this mean?
between 2 and 5 digits
\d{4,}what regex does this mean?
4 or more digits
\d{2}\w? what regex does this mean?
2 digits followed by one or more of [a-zA-Z_]
“\^\d+
what regex does this mean?
’^’ followed by at least one digit
\s+glob\s+
what regex does this mean?
‘glob’ with spaces either side
What is the purpose of the client system
to provide the user an interface to the application
Describe some client functions
- interface to human user
- check and interpret user input
- check and interpret network communication
- report system and network events and errors
What are the 3 components of a simple GUI?
- user input
- application operation
- signalling channel view
What are the 2 different events?
window events(WindowListener) GUI control action events(ActionListener) Client functions
What is the WindowListener?
- interface to window events
- activate, iconify
What is the ActionListener?
- interface to user interaction for application
- called when a user event occurs
- all handling user event handling through this method
What two communications does a thread use?
- user / data plane communication
- control / signalling plane communication
What is the purpose of a server system?
to provide access to resources and provide application services