Package gda.data.metadata.icat
Class NullIcat
java.lang.Object
gda.data.metadata.icat.IcatBase
gda.data.metadata.icat.NullIcat
- All Implemented Interfaces:
Icat
If no Icat configured, then this should be used as the singleton returned by IcatProvider to return meaningful error
messages and responses.
-
Field Summary
Fields inherited from class gda.data.metadata.icat.IcatBase
instrumentName, metadata, operatingDate, username, visitIDFields inherited from interface gda.data.metadata.icat.Icat
ICAT_TYPE_PROP, SHIFT_TOL_PROP, URL_PROP -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiongetCurrentInformation(String accessName) Queries the database filtering using the current username and visit held in metadata.protected StringReturns the access name which is used to find the experiment titlegetMyValidVisits(String username) Return the default experiment defined by either the metadata or the java propertyprotected StringReturns the SQL result for the given accessName string filtered by beamline, username and (optionally) visitID.protected StringReturns the access name which is used to find the visit IDbooleanHas an ICAT been defined for use? Based solely on the java property @seeIcat.ICAT_TYPE_PROPMethods inherited from class gda.data.metadata.icat.IcatBase
getInstrumentName, getMetadata, getMyInformation, getMyInformation, getVisitDataByPrefix, setInstrumentName, setMetadata, setMyVisit, setOperatingDate
-
Constructor Details
-
NullIcat
public NullIcat()
-
-
Method Details
-
icatInUse
public boolean icatInUse()Description copied from class:IcatBaseHas an ICAT been defined for use? Based solely on the java property @seeIcat.ICAT_TYPE_PROP -
getMyValidVisits
Return the default experiment defined by either the metadata or the java property- Specified by:
getMyValidVisitsin interfaceIcat- Overrides:
getMyValidVisitsin classIcatBase- Parameters:
username-- Returns:
- array of valid visit IDs
- Throws:
Exception
-
getCurrentInformation
Description copied from interface:IcatQueries the database filtering using the current username and visit held in metadata.- Specified by:
getCurrentInformationin interfaceIcat- Overrides:
getCurrentInformationin classIcatBase- Parameters:
accessName-- Returns:
- String or null if no information found
- Throws:
Exception
-
getExperimentTitleAccessName
Description copied from class:IcatBaseReturns the access name which is used to find the experiment title- Specified by:
getExperimentTitleAccessNamein classIcatBase
-
getValue
protected String getValue(String visitIDFilter, String userNameFilter, String accessName) throws Exception Description copied from class:IcatBaseReturns the SQL result for the given accessName string filtered by beamline, username and (optionally) visitID. -
getVisitIDAccessName
Description copied from class:IcatBaseReturns the access name which is used to find the visit ID- Specified by:
getVisitIDAccessNamein classIcatBase
-