|
| You are here: Categories » Computers and technology » JAVA
|
The process of writing a custom implementation follows:
1. Choose the appropriate abstract implementation class from the preceding list.
2. Provide implementations for all the class's abstract methods. If your custom collection is to be modifiable, you'll have to override one or more of the concrete methods as well. The API documentation for the abstract implementation class will tell you which methods to override.
3. Test and, if necessary, debug the implementation. You now have a working custom collection implementation.
4. If you're concerned about performance, read the abstract implementation class's API documentation for all the methods whose implementations you're inheriting. If any seem too slow, override them. If you override any methods, be sure to measure the performance of the method before and after the override. How much effort you put into tweaking performance should be a function of how much use the implementation will get and how critical to performance its use is. (Often this step is best omitted.) |
|
Leave a comment or ask a question
|
|
Total comments: 0
Disclaimer
- The e-articles directory is not responsible for any and all copyright infringements by writers and authors. If you suspect the information contained by this page for any copyright infringements, please contact us to investigate the issue
|
|
|
General Java Applet Deployment Considerations - How you deploy an applet depends on whether users access the Web page through the Internet or an Intranet, and the type of browser they use. Note this information about your users, then follow (more...)
SELECTION STATEMENTS IN JAVA - Like other programming languages java offers the control statements to control the execution of a program. The control statements in java are the selection statements, loop constructs and the jump (more...)
JAVA and its Advantages - In today's highly competitive world, JAVA has become one of the most secure technologies for website and software development. Prime benefits of JAVA are platform independency and easy availability (more...)
Introduction to Object Oriented Programming (OOP) - The transition from a procedural programming (non-OOP) language to an object-oriented programming language is a large step for many programmers. It is true that both methods of programming can ulti (more...)
Operator Precedence in programming languages - Operator precedence deciphers the order in which calculations in an expression occur. Looking at the calculation example 3 + 4 * 6, the answer could be calculated by adding 3 and 4, which gives (more...)
Arithmetic Assignment Operators - The following assignment operators are similar to the increment and decrement operators that we have just seen. They are used so that you do not need to enter the source variable twice when ass (more...)
|
|
|