several interfaces, a Java program can inherit only one class at a time, but several interfaces may be implemented, interfaces cannot have any specific methods, and interfaces can be used to define a set of constants that can be used by a class. Its implementation is interface to achieve. Copyright notice: I feel like I'm doing a good job. I hope you can move your mouse and keyboard for me to order a praise or give me a comment, under the Grateful!__
managed by the automatic garbage collector of the Java Virtual machine.Java memory model: According to the instructions in Java Language specification, there is a main memory in the JVM system (main memories or Java Heap memory), and all object members in Java Variables are stored in main memory and are shared for all
First, the Java Foundation1. What do you know about Java modifiers and their respective usage mechanisms? (Public, abstract, final, synchronized, super ...) )01.public: Allow all customers to access02.protected: Used only in this package, in this class, and in subclasses of the class03.private: Only allowed in this class04.abstract: No implementation is provided and the subclass is required to provide the i
Java face test-frame nine
81, what are the benefits of using the spring framework?
Lightweight: Spring is lightweight, the basic version is about 2MB.
Control reversal: Spring enables loose coupling through control inversion, and objects give them dependencies, rather than creating or locating dependent objects.
Aspect-oriented programming (AOP): Spring supports facet-oriented programming and separates app
Java face question ($) 1. Describe the banking business you are familiar with, the more detailed the betterBanking Experience: Mobile banking Online Banking Experience How to pay Transfer understand the basic business2, understand the control of workflow, approval process and accounting processing?How to implement workflow, approval process in Java, How does
1, to finalize the understanding:The finalize- method name. is part of the operating mechanism of the GC operation, and the Finalize method is called when the GC operation is performed. Java technology allows use Finalize () method to do the necessary cleanup before the garbage collector clears the object from memory. This method is called by the garbage collector to this object when it determines that the object is not referenced. It is defined in th
class (immutable), and each operation on a string object generates a new object, and StringBuffer and StringBuilder allow operations on the original object without adding the object each time StringBuffer is thread-safe, but less efficient, while StringBuilder is not the most efficient. This answer I know very early, and the actual application is to do so, often change the time with StringBuilder or StringBuffer. But why this is only recently known, and understand the method is very simple, is
container, and the interceptor does not depend on the servlet container3. Interceptors only work on action requests, while filters can work on almost all requests4. The interceptor can access the action context, the object in the value stack, and the filter cannot5, in the life cycle of the action, the interceptor can be called multiple times, and the filter is only called once when the container is initializedInterceptors: Is programming in the face
consider using the StringBuffer class directly when you need to append strings. Reference answer:The String class is an immutable class, where the string value cannot be changed once it is initialized. StringBuffer is a mutable string class, string-like buffer that can modify the value of a string .3 The difference between StringBuffer and StringbiulderStringBuffer is a thread-safe string buffer, and StringBuilder is not thread-safe .4 wrapper type?The wrapper class includes byte, short, Intege
the object passivation time through the configuration file---object How long it takes to not be passivatedUnder Meta-inf, create a context.xml that reads as follows:@Overridepublic void sessionwillpassivate (Httpsessionevent se) {System.out.println ("Being passivated ... ");}@Overridepublic void sessiondidactivate (Httpsessionevent se) {SYSTEM.OUT.PRINTLN ("Being activated ... ");}When the specified servlet project is accessed, the "passivation" appears after the set time, and then any file und
enable communication and collaboration between multiple threads?Java provides 3 very important ways to skillfully solve communication problems between threads. These 3 methods are: Wait (), notify (), and Notifyall (). They are all the final methods of the object class, so each class has them by default. Although all classes have these 3 methods by default, they are only meaningful if the Synchronized keyword is scoped to the same synchronization pro
enable communication and collaboration between multiple threads?Java provides 3 very important ways to skillfully solve communication problems between threads. These 3 methods are: Wait (), notify (), and Notifyall (). They are all the final methods of the object class, so each class has them by default. Although all classes have these 3 methods by default, they are only meaningful if the Synchronized keyword is scoped to the same synchronization pro
Java face test list for first-line internet companyJava Key knowledge
Multithreading (thread state, thread concurrency, synchronized and lock differences and underlying principles, commonly used locks and their use of scenes and principles,
Volatile and threadlocal solve the problem, the implementation of CAs in Java
Thread pooling principles and implementations
Java Background development face test
Java basic JVM related JUC concurrency related Spring distributed correlation algorithm data structure design pattern database Redis cache related network related other
Java Basics
Arrays.sort realization principle and collection realization principleThe difference between a foreac
100+ Classic Java face question and answer analysisHttps://www.cnblogs.com/pureEve/p/6546280.html2017 Latest Java Face Test (technical interview)77847104Java Polygon Question Set (1-50)17339393Java interview 2018 frequently tested topics Summary (i)78647466The complete collection of questions on
to more of the differences.HashSet in 47.Java, how does the interior work? (Answer answer)The interior of the HashSet is implemented using HashMap. Since the MAP requires key and value, all keys have a default value. Similar to Hashmap,hashset does not allow duplicate keys, only a null key is allowed, meaning that only one null object is allowed in HashSet.48. Write a piece of code to remove an element while traversing ArrayList? AnswerThe key to the
elements in the list. So its performance is O (1). Example 2: The performance of a linear search for an array or list is O (n), because we need to iterate through all the elements to find the elements we need.40. What are the best practices related to the Java collection framework? (1) Select the correct collection type as needed. For example, if you specify a size, we will choose an array instead of a ArrayList. If we want to traverse a map in order
Java face test-multithreaded article 13
121, what is the thread.
A thread is the smallest unit of operation that the operating system can perform, which is included in the process and is the actual unit of operation in the process. Programmers can do multiprocessor programming through it, and you can use multithreading to speed up compute-intensive tasks. For example, if a thread completes a task for 100
understand the content also slowly understand.Before someone said that I did not mean much to study these things, it was important to understand the breadth, not the depth. In fact, it seems to me that this is just a difference in people's values, outlook on life and even world views. (Attached: I actually write the world view, but some people say that even the whole earth does not look at the complete, where the worldview. So, I still have to delete these words. Everyone has a different pursui
: blocking queuesNote the way to use the blocking queue itselfThe Put method is used to deposit elements to the end of the queue, and if the queues are full, wait;The Take method is used to fetch elements from the first team, and if the queue is empty, wait;The Offer method is used to deposit elements to the end of the queue, and if the queues are full, wait for a certain amount of time, and if the time period is reached, false if the insertion is not successful;The poll method is used to take e
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.