Package cn.com; import Java. io. file; import Java. io. filefilter; import Java. util. arraylist; import Java. util. list; // Problem description: count the number of files that meet the conditions in a folder // 1 use filefilter to filter out files
Outline:
The OOP method provides a means to restructure data and methods. Three basic features: encapsulation, inheritance, and Polymorphism
1) classes, fields, and methods
Class Definition: [class modifier] class name [extends parent class
Outline:
1) Basic GUI components: the demo instance is in the/jsdk/demo/jfc/swingset2/directory /;
Overall swing Introduction: javax. swing (lightweight); Java. AWT (highly correlated); containers (components are placed in containers with
1. Implement the comparable interface for objects in the list:
Public class user implements comparable {private string name; private integer order; Public String getname () {return name;} public void setname (string name) {This. name = Name;}
1. Syntax: Must be familiar with writingCodeWhen the IDE editor reports an error for a line, it should be able to know the syntax error based on the error message and know any correction.
2. Commands: You must be familiar with some common commands
R. Java is missing in the automatically generated project,
Choose "right-click your project"> "android Tools"> "Fix Project Properties" on the Internet,
Make sure that the project has been compiled clean, or right-click the project --> Property
Severe warning:You only need to know a little bit about it.
Opening remarks:
I have read an electronic book. I have read too many details but I only remember the name of the book: no-nonsense XML. I was touched by this name. Why? The only
This tutorial is original to enet.Java 2 Micro Edition is a part of Java 2 and is also known as j2se and J2EE. It is a highly optimized Java operating environment and is applied to a large number of consumer electronic devices, such as cell phones,
The relationship between the thread lock of Java and the entry set and wait set, or the figure contains the mysteries of the Java thread. If you do not understand this figure or have never seen it, it only indicates that the Java thread lock is
Document directory
1. Differences between heap and stack in Java
2. Differences between sleep and wait in Java
3. the Java design pattern you have heard
I have interviewed many companies recently. I am deeply touched by some questions about
! Operator& Operator| OperatorAppend method of class jtextareaBoolean logical and (&)Boolean logical exclusive or (^)Boolean logical random sive or (|)BreakCase labelContinueCounter-controlled repetitionDefault case in SwitchDefinite
Suppose the java application code is as follows:Import java. awt .*;Import java. awt. event .*;Import javax. swing .*;Public class MyClass {Public static void main (String [] args ){JFrame f = new JFrame ();F. addWindowListener (new WindowAdapter (){
The following program can add the text box to the scroll bar.
Import java. awt. borderLayout; import java. awt. event. actionEvent; import java. awt. event. actionListener; import javax. swing. boundedRangeModel; import javax. swing. boxLayout;
List usageList includes all the implementation classes of the List interface and List interface. Because the List interface implements the Collection interface, the List interface has all the common methods provided by the Collection interface.
Use spy and memcached for java to operate memcache
I. spy
Package com. test. memcache;
Import java.net. InetSocketAddress;Import java. util. concurrent. Future;Import net. spy. memcached. MemcachedClient;
/*** The package used in this class is a
========================================================== ======================================== The JAVA language was released by sun in May 1995, because of its high security, code optimization, and cross-platform features, it quickly replaces
Byte: eight-digit integer-128--127, which can be used to save memory usage.Short: 16-bit integer-32768--32, 767, also saves memory.Int: 32-bit integer-2,147,483,648 -- 2,147,483,647. Generally, integers are enough.Long: 64-bit integer-9,223,372,036,8
Instanceof:1) classes and classes: Determine the instances on the inheritance chain, generally use the judgment before the strong conversion (when the polymorphism application is used, that is, the polymorphism is used as the form parameter)2)
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