Title: Sams CD Rental Store
Description:
Copyright: Copyright (c) 2004
Company:
NameparamaString String fromString( aString );
fromString( aString );
Indicates whether some other object is "equal to" this one.paramobj the reference object with which to compare.returntrue if this object is the same as the obj argument; false otherwise.todoImplement this java.lang.Object method return ( aName.theValue.equals( this.theValue ) );
true
false
return ( aName.theValue.equals( this.theValue ) );
Indicates whether some other object is "equal to" this one.paramobj the reference object with which to compare.returntrue if this object is the same as the obj argument; false otherwise.todoImplement this java.lang.Object method return equals( ( Name ) obj );
return equals( ( Name ) obj );
fromStringparamaString Stringreturnboolean if ( !StringHelper.containsNoControls( aString ) ) { throw new NameFormatDeviation( ERROR_NAME_BAD_CHARACTERS ); } theValue = aString;
if ( !StringHelper.containsNoControls( aString ) ) { throw new NameFormatDeviation( ERROR_NAME_BAD_CHARACTERS ); } theValue = aString;
return theValue.equals( INVALID_ID );
return new Name( aString );
return theValue;