Package de.pisa.psa.rst.hdl.in
Class PsaRstApiEvtHdlIn
- java.lang.Object
-
- de.pisa.psa.rst.hdl.PsaRstApiEvtHdl
-
- de.pisa.psa.rst.hdl.in.PsaRstApiEvtHdlIn
-
- All Implemented Interfaces:
java.lang.AutoCloseable
- Direct Known Subclasses:
PsaRstApiEvtHdlInDelete
,PsaRstApiEvtHdlInGet
,PsaRstApiEvtHdlInPatch
,PsaRstApiEvtHdlInPost
,PsaRstApiEvtHdlInPut
public abstract class PsaRstApiEvtHdlIn extends PsaRstApiEvtHdl
REST API: incoming event handler- Since:
- 22.06.2023
- Author:
- weiland
-
-
Field Summary
-
Fields inherited from class de.pisa.psa.rst.hdl.PsaRstApiEvtHdl
Default_External_Language, Default_User, Force_IAM_User, Max_Records
-
-
Constructor Summary
Constructors Constructor Description PsaRstApiEvtHdlIn(PsaRstApiEvtHdlDat data)
Constructor
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description protected java.util.List<java.lang.String>
getUsedFields(java.lang.Class<?> object_class)
Get all data object fields that are mapped declared by the PsaRstApiMapFld or annotationprotected de.pisa.psc.srv.dto.PscDto
insertRecord()
create a new data object and insert one recordprotected de.pisa.psc.srv.dto.PscDto
insertRecord(java.lang.Class<? extends PsaRstApiObjBas> object_class)
insert a record in a data objectprotected <T extends PsaRstApiObjBas>
Tjson2object(java.lang.String json, java.lang.Class<T> object_class)
convert a JSON to an REST API objectprotected de.pisa.psc.srv.dto.PscDto
updateRecord(java.lang.Class<? extends PsaRstApiObjBas> object_class)
update a record in a data object-
Methods inherited from class de.pisa.psa.rst.hdl.PsaRstApiEvtHdl
buildResponse, cloneRecords, close, fetchContact, fetchEureka, fetchEurekaRecords, fetchIAMContact, fetchRecord, fetchRecord, fetchRecords, findEmail, getActiveEventHandler, getContinuation, getData, getEurekaDtoQuery, getExternalCommunicationLanguage, getFetchRecordKeyField, getField, getIAMUser, getJsonIncludeEmpty, getQuery, getSsn, getSsnUsr, getSysSsn, handleEvent, isIAMUser, loadRecord, newDto, newObject, newPsaRstApiObjLis, noEventLogging, queryEureka, queryEurekaRecords, queryRecord, queryRecords, setActiveEventHandler, setExternalLanguage, setJsonIncludeEmpty, toJson
-
-
-
-
Constructor Detail
-
PsaRstApiEvtHdlIn
public PsaRstApiEvtHdlIn(PsaRstApiEvtHdlDat data)
Constructor- Parameters:
data
- event data
-
-
Method Detail
-
insertRecord
protected de.pisa.psc.srv.dto.PscDto insertRecord() throws java.lang.Exception
create a new data object and insert one record- Returns:
- the new data object with one row
- Throws:
java.lang.Exception
-
insertRecord
protected de.pisa.psc.srv.dto.PscDto insertRecord(java.lang.Class<? extends PsaRstApiObjBas> object_class) throws java.lang.Exception
insert a record in a data object- Parameters:
object_class
- class of the JSON object- Returns:
- data object with the new row
- Throws:
java.lang.Exception
-
updateRecord
protected de.pisa.psc.srv.dto.PscDto updateRecord(java.lang.Class<? extends PsaRstApiObjBas> object_class) throws java.lang.Exception
update a record in a data object- Parameters:
object_class
- class of the JSON object- Returns:
- data object with the new data
- Throws:
java.lang.Exception
-
json2object
protected <T extends PsaRstApiObjBas> T json2object(java.lang.String json, java.lang.Class<T> object_class)
convert a JSON to an REST API object- Type Parameters:
T
- type of the object- Parameters:
json
- JSONobject_class
- class of the object- Returns:
- object
-
getUsedFields
protected java.util.List<java.lang.String> getUsedFields(java.lang.Class<?> object_class)
Get all data object fields that are mapped declared by the PsaRstApiMapFld or annotation- Parameters:
object_class
- object class- Returns:
- list of field names
-
-