A passage in Java programming thought:When writing a Java source code file, this file is often referred to as a compilation unit (sometimes referred to as a translation unit). Each compilation unit must have a suffix name. java, and within the
PHP gets, checks the class name, function name, method name function method
This article mainly introduces the PHP acquisition, check the class name, function name, method name of the function method, this article summarizes the function of 7
We know that although JavaScript is an object-based (object-based) language. But using its prototype (prototype) feature, we can fully implement the very sexy OO framework, which can be seen in the Classic forum article ' essentially JavaScript OOP (
1. When you use this in an inner class to refer to an object of the inner class, you can use the outer class name to access the Outer class object.2, in Java, each class has a corresponding class object, when a class is written, after compiling, in
The advantage of the Objective-c language is that we are more flexible when writing code, such as we can forward the message to the object we want, or swap the implementation of a method at random. This feature means that objective-c requires not
?? In the C language, you can get the file name and line number through the macro file, lines, in the Java language, you can get the file name, class name, Stacktraceelement class Method name, line number, specific code is as follows:public static
As we all know, in the C language, we can FILE get the __LINE__ file name and line number through the macro, in the Java language, you can StackTraceElement get the file name, class name, method name, line number from the class, the code is as
The wood has the title to say so simple!!
The problem is:
Class A in PHP Inherits Class B, and how to get classes name of Class B in Class A
The actual conditions of use are:
Class B is a base class, multiple classes a,c,d ..... Need to inherit
Keywords: Enterprise application
Just see the discussion about log. Think of a problem that was previously investigated. Sorted out, hope to be helpful to everyone.
Sun JDK source code Download http://wwws.sun.com/software/communitysource/Register
Below I present you and different ways to get the current Class:
Using Thread
Using GetClass ()
The simplest-to-get the name of the class where your code is being executed in are using the getClass() method present in Ev Ery Java
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.