|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||
java.lang.ObjectcacheRunner.Portfolio
public class Portfolio
A stock portfolio that consists of multiple Position
objects that represent shares of stock (a "security"). Instances
of Portfolio can be stored in a GemFire
Region and their contents can be queried using the
GemFire query service.
This class is Serializable because we want it to be
distributed to multiple members of a distributed system. Because
this class is Declarable, we can describe instances of
it in a GemFire cache.xml file.
| Constructor Summary | |
|---|---|
Portfolio()
|
|
| Method Summary | |
|---|---|
int |
getId()
Returns the id of this portfolio. |
Map |
getPositions()
Returns the positions held in this portfolio. |
String |
getStatus()
Returns the status of this portfolio ( active or
inactive). |
String |
getType()
Returns the type of this portfolio. |
void |
init(Properties props)
Initializes an instance of Portfolio from a
Properties object assembled from data residing in a
cache.xml file. |
boolean |
isActive()
Returns whether or not this portfolio is active. |
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Constructor Detail |
|---|
public Portfolio()
| Method Detail |
|---|
public void init(Properties props)
Portfolio from a
Properties object assembled from data residing in a
cache.xml file.
init in interface Declarablepublic String getStatus()
active or
inactive).
public int getId()
Portfolio
placed in a GemFire Region entry, its id is used as
the key.
public Map getPositions()
Map whose keys are the security ids and whose values are
Position objects.public String getType()
public boolean isActive()
public String toString()
toString in class Object
|
|||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | ||||||||