Class BuilderIF
java.lang.Object
|
+--BuilderIF
- Direct Known Subclasses:
- BuilderEconomy
- public abstract class BuilderIF
- extends java.lang.Object
Factory class to create accounts and security managers.
The structure follows the Builder pattern.
Account and security manager are created by implementations.
- See Also:
- package account.
Field Summary |
static int |
ECONOMY
Type token for economy concrete builder. |
static int |
PROFESSIONAL
Type token for prionalofes concrete builder. |
static int |
STANDARD
Type token for standard concrete builder. |
Method Summary |
abstract pattpack.account.AccountIF |
createAccount(int loginId)
Create an account. |
abstract pattpack.account.SecurityManagerIF |
createSecurityManager()
Create a security manager. |
static BuilderIF |
getInstance(int type)
Return an object of the class appropriate for
the account and security manager requested by the argument. |
Methods inherited from class java.lang.Object |
,
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
registerNatives,
toString,
wait,
wait,
wait |
ECONOMY
public static final int ECONOMY
- Type token for economy concrete builder.
STANDARD
public static final int STANDARD
- Type token for standard concrete builder.
PROFESSIONAL
public static final int PROFESSIONAL
- Type token for prionalofes concrete builder.
BuilderIF
public BuilderIF()
getInstance
public static BuilderIF getInstance(int type)
- Return an object of the class appropriate for
the account and security manager requested by the argument.
- Parameters:
type
- The type token of the concrete builder,
e.g., "economy", "standard", etc.- Returns:
- a concrete builder of the requested type.
createAccount
public abstract pattpack.account.AccountIF createAccount(int loginId)
- Create an account.
- Parameters:
loginId
- the id of the created account.- Returns:
- the created account.
createSecurityManager
public abstract pattpack.account.SecurityManagerIF createSecurityManager()
- Create a security manager.
- Returns:
- the created security manager.