We are an award-winning tech entrepreneurship website where trusted experts can provide value globally.

Since 1998, DevX has helped people start businesses, build websites, and provide enterprise technology to people globally. Interviewing the likes of Microsoft’s co-founder, Steve Ballmer, the publication brings comprehensive, reliable, and accessible insights to the Internet.

devxlogo

Trusted for 26 years

Over 30K Articles

1M+ Readers

Expert-reviewed

10K+ Tech Terms

As seen in:

microsoft logo
business_insider_logo
wired_logo
berkley
arstechnica_logo
hackernoon

The Latest

DevX - Software Development Resource

Methods of Class Instantiation

The following methods can be used for creating new instance of your classes, depending on your specific needs. import java.lang.ClassLoader;import java.net.URLClassLoader;import java.net.URL;public class InstantiateClass { testFinally newInstance() throws Exception {

DevX - Software Development Resource

Using Verbose to Debug

Using the -verbose option during compilation and execution is very helpful&#151both for obtaining more information about the classes being loaded by the compiler and the interpreter and to find out

DevX - Software Development Resource

A Problem in Using Enumeration

Once you are finished iterating through the values of an Object implementing the Enumeration interface, the next time youtry to use hasMoreElements() it will return false. Many developers are not

DevX - Software Development Resource

How to Rethrow an Exception in Your Code

Use the fillInStackTrace() method to rethrow a Throwable type of exceptional condition in your code. This is useful if you want to rethrow a exception occurred while using a method

DevX - Software Development Resource

Creating a Numeric-Input JTextField

Validating user input that is typed into a JTextField can becumbersome, especially if the input string must be converted to anumeric value such as an int. By subclassing JTextField, however,

DevX - Software Development Resource

Boolean Literals

The keywords false and true are Boolean literals that evaluate to 0 and 1 respectively. Note that in other programming language, VB for instance, false equals -1 and true equals

DevX - Software Development Resource

Casting Pointers To Members

C++ allows casting a pointer to member functions of one type to another pointer to member, as long as the signatures of the two match. However, the results of such

DevX - Software Development Resource

Hardcoded Char Arrays

Does your C++ compiler accept the following code? char s[3]=”abc”; // illegal in C++, no place for ” The standard requires that the size of a char array initialized with

DevX - Software Development Resource

Violating an Exception Specification

The implementation ensures that functions having an exception specification should throw only exceptions that are listed in their exception specification. For example: class X{};class Y{};void f() throw X{ throw Y();

DevX - Software Development Resource

Binding a Reference to an Rvalue

In a previous tip, http://www.devx.com/free/tips/tipview.asp?content_id=1585 , I explained the concept of lvalues and rvalues. Binding a reference to an rvalue is allowed as long as the reference is const. The

DevX - Software Development Resource

Extracting a Program’s Name

The name of the executable is stored in the string argv[0]. To access it, declare your main() function as follows: int main(int argc, char ** argv) Even if the application

DevX - Software Development Resource

Helper Functions

The interface of a class consists of its public members. Usually, private members represent implementation details and are not exposed to other classes and users. Private members can be member

DevX - Software Development Resource

JDBC Transactions

Question: Does “Connection.setAutoCommit(false)” mean “begin a transaction?” Answer: By default, JDBC connections start in autocommit mode. This means that every executed statement is treated as a separate transaction. A transaction

DevX - Software Development Resource

Storing InitialContext in Servlet Sessions

Question: Suppose a client of a Web application logs in using a login-handler servlet, and then some back-end operations using EJBs need to be performed. Can I store the initial

DevX - Software Development Resource

JavaBeans vs. Enterprise JavaBeans

Question: What is the difference between a JavaBean and an Enterprise JavaBean? Answer: It is natural to be confused regarding the relationship between JavaBeans and Enterprise JavaBeans (EJBs), because they

DevX - Software Development Resource

ResultSet Interface

Question: If ResultSet is an interface, then why can we call methods like next(), isLast() etc. without defining the method body anywhere in the program? As I understand it, in

DevX - Software Development Resource

Memory Allocation

Question: What is the reason that allocated memory should be explicitly deallocated ? Is there any difference in the way the data with different storage types (stack, heap, static memory)

DevX - Software Development Resource

Changing a Character’s Case

Question: Is there a function that can convert upper case to lower case and vice-versa? Answer: The toupper() and tolower() functions are declared in the standard header. Each of them

DevX - Software Development Resource

Multidimensional Arrays and Classes

Question: I am currently writing a program that uses multidimensional arrays to store and display data items. My problem is that I cannot seem to change the array values from

DevX - Software Development Resource

The MB Scroller Control

Have you ever spent your time trying to arrange too many controls on a form that was too small for all of them? Now you can relax, at last. Just

DevX - Software Development Resource

Split large HTML tables in smaller ones

In general, a browser can’t render an HTML table before the closing &/TABLE> tag is received. This means that the end user might wait for several seconds before a table

DevX - Software Development Resource

Avoid querying the ServerVariables collection

You can access a lot of useful information through the ServerVariables collection, but this has a price in terms of performance. More precisely, the first time you reference this collection

DevX - Software Development Resource

The MapPath method slows down execution

The Server.MapPath method slightly shows down the execution of your ASP scripts, because IIS has to access some internal variables. For this reason you should try to avoid it if

DevX - Software Development Resource

Use Response.IsClientConnected after long queries

When you perform a complex and time-consuming query in your ASP program, you should periodically test whether the client is still connected, using the IsClientConnected method of the Response object,

DevX - Software Development Resource

Buffering is on by default in IIS 5

You can speed up ASP by adding the following statement at the beginning of an ASP page: Response.Buffer = True This statement must be executed before any HTML text is

DevX - Software Development Resource

Advanced Find – Words Within a Document

Question: I’m trying to use the Advanced Find feature of Outlook to locate attachments that contain a specific word (analogous to the Containing Text feature of Windows’ Find feature). I