public class NCMBServicePool
extends java.lang.Object
Modifier and Type | Field and Description |
---|---|
protected java.util.Map<NCMB.ServiceType,java.util.HashMap<NCMBContext,NCMBService>> |
pool
stored services
|
Constructor and Description |
---|
NCMBServicePool()
Constructor
|
Modifier and Type | Method and Description |
---|---|
boolean |
exists(NCMB.ServiceType serviceType,
NCMBContext context)
Return service object is already cached
|
NCMBService |
get(NCMB.ServiceType serviceType,
NCMBContext context)
Get service object
|
protected java.util.HashMap<NCMBContext,NCMBService> |
getServices(NCMB.ServiceType serviceType)
Get context-keyed hash of given service type
|
NCMBService |
newService(NCMB.ServiceType serviceType,
NCMBContext context)
Create service object and return it
|
protected java.util.Map<NCMB.ServiceType,java.util.HashMap<NCMBContext,NCMBService>> pool
public NCMBService get(NCMB.ServiceType serviceType, NCMBContext context)
serviceType
- service typecontext
- contextpublic boolean exists(NCMB.ServiceType serviceType, NCMBContext context)
serviceType
- service typecontext
- contextprotected java.util.HashMap<NCMBContext,NCMBService> getServices(NCMB.ServiceType serviceType)
serviceType
- service typepublic NCMBService newService(NCMB.ServiceType serviceType, NCMBContext context)
serviceType
- service typecontext
- context