1 PackageZhang;2 /**3 * Java Reflection class exercises4 * 5 * In Object-oriented language, everything is object, so who is the object of the class? 6 * Classes are of class type7 * 8 * */9 classtest{Ten voidprint () { OneSystem.out.println (
The value of the basic data type parameter, which is the base data typeclasscomputer{intAddintXinty) { returnx+y; }} Public classExample4_6 { Public Static voidMain (String args[]) {computer COM=Newcomputer (); intm = 100; intn = 200;
1. Java APIPublic T cast (Object obj);Casts an object to the class or interface representedThe explanation is more general, meaning to replace an object with a class or interface.2. code example/*** Created by Shengke on 2016/10/22.*/classA { Public
A static member function of a class cannot access non-static member functions and non-static member variables.But the reverse is true.That is, non-static member functions can access static member functions and static member variables.This can be
----BasicsCreate a Form ObjectJFrame frame = new JFrame ();Set Window sizeFrame.setsize (300, 200);Specify where the window appearsFrame.setlocation (300, 200);Specify the title bar of the windowFrame.settitle ("MY FRIST windows!");Get the contents
It probably says equals and = = Compare What:1. Boolean tem = a = = B;The first = = comparison is definitely the address, from the stack point of view that is = = Compare the contents of the stack above. Because the stack is used to store the
1. Data types can be divided into 2 categories: basic data types and composite data types.Basic data types: integer, float, character, and characterComposite data types: array type, class, interfaceBasic data Types1. Integral type Basic type (int)
Modifiers in the Java language----------------------------------------------------------------------------------------------The available modifiers for classes, methods, member variables, and local variablesAccess Control Level
One, run-time exception1. Null pointer (java.lang.NullPointerException)2. Type conversion ()3, array subscript out of bounds (java.lang.ArrayIndexOutOfBoundsException)4. Arithmetic Anomalies (java.lang.ArithmeticException)5. The specified class does
1. Object oriented (Overview of Object oriented thinking)
A: Overview of process-oriented thinking
The first step
Step Two
B: An overview of object-oriented thinking
Find objects (first step, second
Available modifiers for classes, methods, member variables, and local variables
Modifier
Class
Member Methods
Construction method
Member variables
Local variables
Abstract
Y
Y
_
Active ObjectThrough the proxy interface, the production, cache, consumption scenarios in the cache, consumption and production part of the Independent, through the future mode return operation results to the production part.The cache section
Basic Java Learning--abstract classes and abstract functions
Abstract class
An abstract class cannot make an object, but a variable can be defined, and the object assigned to the variable must be a non-abstract subclass of it;
Abstract
Send the code first, and have time to write the content.Observer11 ImportJava.util.Observer;2 Importjava.util.Observable;3 4 //Student Class (Student) can be observed after inheriting observable5 classStudentextendsobservable{6 //Properties7
Given n non-negative integers representing the histogram ' s bar height where the width of each bar is 1, find the Area of largest rectangle in the histogram.Above is a histogram the where width of each bar is 1, given height = [2,1,5,6,2,3] .The
WindedThere are two types of threads in Java: User thread, Daemon thread (daemon thread)
Definition: A daemon thread (AKA: Service thread) that automatically leaves when no user thread is available for service.
Priority: The daemon
MPs queue stream and MPs queue
Link: http://www.bdqn.cn/news/201303/8270.shtml
A pipeline stream can transmit binary data between two threads.
A pipe stream is like a pipe where data is input at one end and data is output at another end. Usually
Spring: authenticates user logon. spring authenticates user logon.
The Spring IOC technology is used to verify user logon.
First, inject the User object into the controller using Spring's automatic assembly mode, and then match the User name and
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.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service