Sample: Master/Detail Relationship

Demonstration:

  1. public String()
  2. public String(StringBuffer buffer)
  3. public String(String original)
  4. public String(char[] value)
  5. public String(byte[] bytes)
Initializes a newly created String object so that it represents an empty character sequence. Note that use of this constructor is unnecessary since Strings are immutable.
Allocates a new string that contains the sequence of characters currently contained in the string buffer argument. The contents of the string buffer are copied; subsequent modification of the string buffer does not affect the newly created string. Parameters:
Initializes a newly created String object so that it represents the same sequence of characters as the argument; in other words, the newly created string is a copy of the argument string. Unless an explicit copy of original is needed, use of this constructor is unnecessary since Strings are immutable. Parameters:
Allocates a new String so that it represents the sequence of characters currently contained in the character array argument. The contents of the character array are copied; subsequent modification of the character array does not affect the newly created string. Parameters:
  • char[] value: the initial value of the string.
Constructs a new String by decoding the specified array of bytes using the platform's default charset. The length of the new String is a function of the charset, and hence may not be equal to the length of the byte array.

The behavior of this constructor when the given bytes are not valid in the default charset is unspecified. The java.nio.charset.CharsetDecoder class should be used when more control over the decoding process is required.

Parameters:
  • byte[] bytes: the bytes to be decoded into characters

Description:

Displaying a page containing a list of items (with titles and brief descriptions) where longer descriptions exist on the page for each item in the list. The issue is that there is not enough space on the page to display all long descriptions. CSS positioning and the visibility attribute can be used to toggle the long description for only one list item of interest.

The list becomes more akin to a selector. Clicking on a list item displays the long description. This is an example of effective use of visibility to filter out information that the end user does not need or want in his focus at a particular moment.


References

[tbd]: javadocs - methods listing with method details. others?