Class RemoteObjectLight
- java.lang.Object
-
- org.neotropic.kuwaiba.northbound.ws.model.business.RemoteObjectLight
-
- All Implemented Interfaces:
Serializable,Comparable<RemoteObjectLight>
- Direct Known Subclasses:
RemoteObject
public class RemoteObjectLight extends Object implements Serializable, Comparable<RemoteObjectLight>
This class is a simple representation of an object. It's used for trees and view. This is jus an entity wrapper- Author:
- Charles Edward Bedon Cortazar <charles.bedon@kuwaiba.org>
- See Also:
- Serialized Form
-
-
Field Summary
Fields Modifier and Type Field Description static StringDATA_TYPEMIME Type used mainly while dragging and dropping nodes representing RemoteObjectLightsprotected List<RemoteValidator>validatorsMisc flags used to give more information about the object (i.e.
-
Constructor Summary
Constructors Modifier Constructor Description protectedRemoteObjectLight()Default constructor.RemoteObjectLight(String className, String oid, String name)RemoteObjectLight(BusinessObjectLight obj)
-
Method Summary
All Methods Static Methods Instance Methods Concrete Methods Modifier and Type Method Description voidaddValidator(RemoteValidator newValidator)intcompareTo(RemoteObjectLight o)booleanequals(Object obj)StringgetClassName()StringgetId()StringgetName()List<RemoteValidator>getValidators()Validators are flags indicating things about objects.inthashCode()voidsetName(String name)static List<RemoteObjectLight>toRemoteObjectLightArray(List<BusinessObjectLight> toBeWrapped)StringtoString()
-
-
-
Field Detail
-
DATA_TYPE
public static final String DATA_TYPE
MIME Type used mainly while dragging and dropping nodes representing RemoteObjectLights- See Also:
- Constant Field Values
-
validators
protected List<RemoteValidator> validators
Misc flags used to give more information about the object (i.e. is it already connected?)
-
-
Constructor Detail
-
RemoteObjectLight
protected RemoteObjectLight()
Default constructor. Not used
-
RemoteObjectLight
public RemoteObjectLight(BusinessObjectLight obj)
-
-
Method Detail
-
getClassName
public String getClassName()
-
getId
public String getId()
-
getName
public String getName()
-
setName
public void setName(String name)
-
getValidators
public List<RemoteValidator> getValidators()
Validators are flags indicating things about objects. Of course, every instance may have something to expose or not. For instance, a port has an indicator to mark it as "connected physically", but a Building (so far) has nothing to "indicate". This is done in order to avoid a second call to query for a particular information that could affect the performance. I.e: Call 1: getPort (retrieving a LocalObjectLight) Call 2: isThisPortConnected (retrieving a boolean according to a condition) With this method there's only one call getPort (a LocalObjectLight with a flag to indicate that the port is connected) Why not use getPort retrieving a LocalObject? Well, because the condition might be complicated, and it's easier to compute its value at server side. Besides, it can involve complex queries that would require more calls to the webservice- Returns:
- a list with the validators
-
addValidator
public void addValidator(RemoteValidator newValidator)
-
toRemoteObjectLightArray
public static List<RemoteObjectLight> toRemoteObjectLightArray(List<BusinessObjectLight> toBeWrapped)
-
compareTo
public int compareTo(RemoteObjectLight o)
- Specified by:
compareToin interfaceComparable<RemoteObjectLight>
-
-