代码搜索:Getting

找到约 2,749 项符合「Getting」的源代码

代码结果 2,749
www.eeworm.com/read/127767/14337229

txt e1043. getting a request header in a servlet.txt

This example demonstrates how to get the value of a request header in either a GET or POST request. // See also e1035 The Quintessential Servlet // This method is called by the servle
www.eeworm.com/read/127767/14337287

txt e411. getting the roots of the preference trees.txt

There are two preference trees --- the system tree and the user tree. The root of these trees is retrieved using Preferences.systemRoot() and Preferences.userRoot(). The roots are required when creati
www.eeworm.com/read/127767/14337316

txt e144. getting the ip address of a hostname.txt

try { InetAddress addr = InetAddress.getByName("javaalmanac.com"); byte[] ipAddr = addr.getAddress(); // Convert to dot representation String ipAddrStr = "";
www.eeworm.com/read/127767/14337362

txt e777. getting the items in a jlist component.txt

// Create a list String[] items = {"A", "B", "C", "D"}; JList list = new JList(items); // Get number of items in the list int size = list.getModel().getSize(); // 4
www.eeworm.com/read/127767/14337434

txt e572. getting the child components of a container.txt

This example retrieves all of a container's children in an array: // Get children Component[] components = container.getComponents(); for (int i=0; i
www.eeworm.com/read/127767/14337542

txt e1018. getting the text in an html document.txt

// This method takes a URI which can be either a filename (e.g. file://c:/dir/file.html) // or a URL (e.g. http://host.com/page.html) and returns all text in the document. public static Stri
www.eeworm.com/read/127767/14337592

txt e291. getting the name of a jdbc type.txt

This example implements a convenient method for converting a java.sql.Types integer value into a printable name. This method is useful for debugging. The method uses reflection to get all the field na
www.eeworm.com/read/127767/14337631

txt e528. getting the notations in a dom document.txt

The notations declared in the DTD of an XML document are available in the DocumentType object of a DOM document. // Obtain a document; the following method is implemented in // e510 The Qui
www.eeworm.com/read/127767/14337635

txt e101. getting the stack trace of an exception.txt

try { // My code } catch (Throwable e) { // Get the stack trace StackTraceElement stack[] = e.getStackTrace(); // stack[0] contains the method that creat
www.eeworm.com/read/127767/14337723

txt e145. getting the hostname of an ip address.txt

This example attempts to retrieve the hostname for an IP address. Note that getHostName() may not succeed, in which case it simply returns the IP address. try { // Get hostname by textu