Docjar: A Java Source and Docuemnt Enginecom.*    java.*    javax.*    org.*    all    new    plug-in

Quick Search    Search Deep

openfuture.masterdata
Class DefaultMasterDataProvider  view DefaultMasterDataProvider download DefaultMasterDataProvider.java

java.lang.Object
  extended byopenfuture.masterdata.DefaultMasterDataProvider
All Implemented Interfaces:
ILanguageDependent, IMasterDataProvider

public class DefaultMasterDataProvider
extends java.lang.Object
implements IMasterDataProvider, ILanguageDependent

This is a default implementation for a Master Data provider. Creation date: (09.09.00 21:59:30)


Field Summary
private  java.lang.String language
          Field language (String) is used to identify the language of the provider
private  java.util.Hashtable masterDataCache
          Field masterDataCache (Hashtable) is used to cache the master data in the provider
private  IMasterDataService service
          Field service (IMasterDataService) is used to connect provider to service
 
Constructor Summary
DefaultMasterDataProvider()
          Constructor
 
Method Summary
private  IMasterDataContainer fetchMasterData(java.lang.String type)
          fetch master data form the service Creation date: (11.09.00 09:53:46)
private  java.lang.String getKey(java.lang.String type, java.lang.String language)
          get a Hashtable key for a given type and language Creation date: (11.09.00 14:48:24)
 java.lang.String getLanguage()
          Return contents of field language
 java.util.Vector getMasterData(java.lang.String type)
          get some master data from the cache; if no data available in the provider, data are fetched from the service
 IMasterData getMasterData(java.lang.String type, java.lang.String id)
          get some master data from the cache for a given language
 java.util.Hashtable getMasterDataCache()
          Return contents of field masterDataCache
 IMasterDataService getService()
          Return contents of field service
 void setLanguage(java.lang.String newValue)
          Set contents of field language to the given value
 void setMasterDataCache(java.util.Hashtable newValue)
          Set contents of field masterDataCache to the given value
 void setService(IMasterDataService newValue)
          Set contents of field service to the given value
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

service

private IMasterDataService service
Field service (IMasterDataService) is used to connect provider to service


masterDataCache

private java.util.Hashtable masterDataCache
Field masterDataCache (Hashtable) is used to cache the master data in the provider


language

private java.lang.String language
Field language (String) is used to identify the language of the provider

Constructor Detail

DefaultMasterDataProvider

public DefaultMasterDataProvider()
Constructor

Method Detail

fetchMasterData

private IMasterDataContainer fetchMasterData(java.lang.String type)
fetch master data form the service Creation date: (11.09.00 09:53:46)


getKey

private java.lang.String getKey(java.lang.String type,
                                java.lang.String language)
get a Hashtable key for a given type and language Creation date: (11.09.00 14:48:24)


getLanguage

public java.lang.String getLanguage()
Return contents of field language

Specified by:
getLanguage in interface ILanguageDependent

getMasterData

public java.util.Vector getMasterData(java.lang.String type)
get some master data from the cache; if no data available in the provider, data are fetched from the service

Specified by:
getMasterData in interface IMasterDataProvider

getMasterData

public IMasterData getMasterData(java.lang.String type,
                                 java.lang.String id)
get some master data from the cache for a given language

Specified by:
getMasterData in interface IMasterDataProvider

getMasterDataCache

public java.util.Hashtable getMasterDataCache()
Return contents of field masterDataCache


getService

public final IMasterDataService getService()
Return contents of field service


setLanguage

public void setLanguage(java.lang.String newValue)
Set contents of field language to the given value

Specified by:
setLanguage in interface ILanguageDependent

setMasterDataCache

public void setMasterDataCache(java.util.Hashtable newValue)
Set contents of field masterDataCache to the given value


setService

public final void setService(IMasterDataService newValue)
Set contents of field service to the given value