Class WsSubject
java.lang.Object
edu.internet2.middleware.grouper.ws.coresoap.WsSubject
- All Implemented Interfaces:
Comparable<WsSubject>
subject bean for web services
-
Nested Class Summary
Modifier and TypeClassDescriptionstatic enum
result code of a request -
Field Summary
Modifier and TypeFieldDescriptionstatic final String
prefix of attribute that refers to subject: subject. -
Constructor Summary
ConstructorDescriptionconstructorWsSubject
(Member member, String[] subjectAttributeNames, WsSubjectLookup subjectLookup, boolean includeSubjectDetails) construct with member to set internal fieldsWsSubject
(PITMember pitMember, String[] subjectAttributeNames, WsSubjectLookup subjectLookup, boolean includeSubjectDetails) construct with member to set internal fieldsWsSubject
(WsSubjectLookup wsSubjectLookup) this is a temporary constructor to just put the lookup info here in case there is an error retrieving the subject constructorWsSubject
(Subject subject, String[] subjectAttributeNames, WsSubjectLookup wsSubjectLookup) constructor to convert jdbc subject to a ws subject -
Method Summary
Modifier and TypeMethodDescriptionvoid
assignResultCode
(WsSubject.WsSubjectResultCode wsSubjectResultCode) assign the code from the enumint
static WsSubject[]
convertMembers
(Set<Member> memberSet, String[] attributeNames, boolean includeSubjectDetail) convert members to subject resultsString[]
if attributes are being sent back per config in the grouper.properties, this is attribute0 value, this is extended subject datagetId()
subject id, note if no subject found, and identifier was passed in, that will be placed hereidentifier used to lookup subjectgetName()
T or F for successvoid
setAttributeValues
(String[] attributesa) attribute data of subjects in group (in same order as attributeNames)void
subject id, note if no subject found, and identifier was passed in, that will be placed herevoid
setIdentifierLookup
(String identifierLookup1) return the identifier looked upvoid
setMemberId
(String memberId1) void
void
setResultCode
(String resultCode1) void
setSourceId
(String source1) void
setSuccess
(String success1) T or F for successtoString()
make sure this is an explicit toString
-
Field Details
-
SUBJECT_ATTRIBUTE_PREFIX
prefix of attribute that refers to subject: subject.- See Also:
-
-
Constructor Details
-
WsSubject
public WsSubject()constructor -
WsSubject
this is a temporary constructor to just put the lookup info here in case there is an error retrieving the subject constructor- Parameters:
wsSubjectLookup
- to be based on (assuming subject not found, just copy the fields
-
WsSubject
constructor to convert jdbc subject to a ws subject- Parameters:
subject
- (can be null)subjectAttributeNames
- (should be calculated based on if detail or not)wsSubjectLookup
- can be null, else the lookup which got the subject
-
WsSubject
public WsSubject(Member member, String[] subjectAttributeNames, WsSubjectLookup subjectLookup, boolean includeSubjectDetails) construct with member to set internal fields- Parameters:
member
-subjectAttributeNames
- are the attributes the user is getting (either requested or in config) (should be calculated for is detail or not)subjectLookup
-includeSubjectDetails
-retrieveExtendedSubjectDataBoolean
- true to retrieve subject info (more than just the id)
-
WsSubject
public WsSubject(PITMember pitMember, String[] subjectAttributeNames, WsSubjectLookup subjectLookup, boolean includeSubjectDetails) construct with member to set internal fields- Parameters:
pitMember
-subjectAttributeNames
- are the attributes the user is getting (either requested or in config) (should be calculated for is detail or not)subjectLookup
-includeSubjectDetails
-
-
-
Method Details
-
getIdentifierLookup
identifier used to lookup subject- Returns:
- the identifier
-
setIdentifierLookup
return the identifier looked up- Parameters:
identifierLookup1
-
-
toString
make sure this is an explicit toString -
convertMembers
public static WsSubject[] convertMembers(Set<Member> memberSet, String[] attributeNames, boolean includeSubjectDetail) convert members to subject results- Parameters:
attributeNames
- to get from subjectsmemberSet
-includeSubjectDetail
-- Returns:
- the subject results
-
getId
subject id, note if no subject found, and identifier was passed in, that will be placed here- Returns:
- the id
-
setId
subject id, note if no subject found, and identifier was passed in, that will be placed here- Parameters:
id1
-
-
getName
- Returns:
- the name
-
setName
- Parameters:
name1
- the name to set
-
getAttributeValues
if attributes are being sent back per config in the grouper.properties, this is attribute0 value, this is extended subject data- Returns:
- the attribute0
-
setAttributeValues
attribute data of subjects in group (in same order as attributeNames)- Parameters:
attributesa
- the attributes to set
-
getSourceId
- Returns:
- the source
-
setSourceId
- Parameters:
source1
- the source to set
-
getMemberId
- Returns:
- the memberId
-
setMemberId
- Parameters:
memberId1
- the uuid to set
-
getResultCode
- Returns:
- the resultCode
-
setResultCode
- Parameters:
resultCode1
- the resultCode to set
-
assignResultCode
assign the code from the enum- Parameters:
wsSubjectResultCode
-
-
getSuccess
T or F for success- Returns:
- the success
-
setSuccess
T or F for success- Parameters:
success1
- the success to set
-
compareTo
- Specified by:
compareTo
in interfaceComparable<WsSubject>
- See Also:
-