com.jwpepper.cat
Class EntryItemReference

java.lang.Object
  |
  +--com.imaginary.lwp.BaseReference
        |
        +--com.jwpepper.cat.EntryItemReference

public abstract class EntryItemReference
extends BaseReference

References a specific entry item entity class and provides methods that delegate to that entry item.
Last modified $Date: 1999/10/05 21:00:50 $

Version:
$Revision: 1.1 $
Author:
George Reese (george@ancept.com)
See Also:
Serialized Form

Constructor Summary
EntryItemReference()
          Empty constructor required for serialization.
EntryItemReference(EntryItem ent)
          Constructs a new entry item reference tied to the specified entry item.
EntryItemReference(long oid)
          Constructs a new entry item reference tied to the object with the specified objectID.
 
Method Summary
 void assign(long oid, com.sun.java.util.collections.HashMap vals)
          Associated this reference with the preloaded values specified.
 java.lang.String getDescription(java.util.Locale loc)
          Provides the description for this entry item as if it were the primary entry in the entry in which it is contained.
 SimpleEntryReference getEntry()
          Provides the entry that owns this entry item.
 java.lang.String getLineDescription(java.util.Locale loc)
          Provides the description of this entry item as if it were a secondary entry item in the entry in which it is contained.
 java.util.Properties getProperties()
          Provides the properties associated with this entry item.
 java.lang.String getTitle(java.util.Locale loc)
          Provides the title for this entry item.
 
Methods inherited from class com.imaginary.lwp.BaseReference
assign, assign, get, getEntity, getLastUpdateID, getLastUpdateTime, getObjectID, put, reconnect
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

EntryItemReference

public EntryItemReference()
Empty constructor required for serialization.

EntryItemReference

public EntryItemReference(long oid)
Constructs a new entry item reference tied to the object with the specified objectID.
Parameters:
oid - the objectID of the object to which it is tied

EntryItemReference

public EntryItemReference(EntryItem ent)
                   throws java.rmi.RemoteException
Constructs a new entry item reference tied to the specified entry item.
Parameters:
the - entity to which this reference is tied
Throws:
java.rmi.RemoteException - a network error occurred
Method Detail

assign

public void assign(long oid,
                   com.sun.java.util.collections.HashMap vals)
Associated this reference with the preloaded values specified.
Parameters:
oid - the objectID of the object to which this reference is tied
vals - the preloaded values
Overrides:
assign in class BaseReference

getDescription

public java.lang.String getDescription(java.util.Locale loc)
                                throws java.rmi.RemoteException
Provides the description for this entry item as if it were the primary entry in the entry in which it is contained.
Parameters:
loc - the locale for which the description should be translated
Returns:
the description of the entry item
Throws:
java.rmi.RemoteException - a network error occurred

getEntry

public SimpleEntryReference getEntry()
                              throws java.rmi.RemoteException
Provides the entry that owns this entry item.
Returns:
the owning entry
Throws:
java.rmi.RemoteException - a network error occurred

getLineDescription

public java.lang.String getLineDescription(java.util.Locale loc)
                                    throws java.rmi.RemoteException
Provides the description of this entry item as if it were a secondary entry item in the entry in which it is contained.
Parameters:
loc - the locale for which the text should be translated
Returns:
the line description for the entry item
Throws:
java.rmi.RemoteException - a network error occurred

getProperties

public java.util.Properties getProperties()
                                   throws java.rmi.RemoteException
Provides the properties associated with this entry item. Because the catalog system interfaces with the things being represented in the catalog via the EntryItem concept, data specific to what individual things need are stored in properties. For example, for J.W. Pepper products, price information is stored in properties.
Returns:
the properties for this entry item
Throws:
java.rmi.RemoteException - a network error occurred

getTitle

public java.lang.String getTitle(java.util.Locale loc)
                          throws java.rmi.RemoteException
Provides the title for this entry item.
Parameters:
loc - the locale for which the title should be translated
Returns:
the entry item title
Throws:
java.rmi.RemoteException - a network error occurred