Class MoodleClientConnection
java.lang.Object
org.jdrupes.keycloak.moodleauth.moodle.MoodleClientConnection
- All Implemented Interfaces:
AutoCloseable
,MoodleClient
Represents an open connection to a moodle instance.
-
Constructor Summary
ConstructorDescriptionMoodleClientConnection
(URI siteUri, RestClient restClient, MoodleUser moodleUser, MoodleSiteInfo siteInfo) Instantiates a new moodle client connection. -
Method Summary
-
Constructor Details
-
MoodleClientConnection
public MoodleClientConnection(URI siteUri, RestClient restClient, MoodleUser moodleUser, MoodleSiteInfo siteInfo) Instantiates a new moodle client connection.- Parameters:
restClient
- the rest client
-
-
Method Details
-
invoke
Description copied from interface:MoodleClient
Invoke some function.Allows the invocation of functions that haven’t been typed yet.
- Specified by:
invoke
in interfaceMoodleClient
- Parameters:
wsfunction
- the functionparams
- the parameters- Returns:
- the result
- Throws:
IOException
-
moodleUser
Description copied from interface:MoodleClient
The authenticated moodle user.- Specified by:
moodleUser
in interfaceMoodleClient
- Returns:
- the moodle user
-
siteInfo
Description copied from interface:MoodleClient
The site info (includes information about the user)- Specified by:
siteInfo
in interfaceMoodleClient
- Returns:
- the moodle site info
-
close
- Specified by:
close
in interfaceAutoCloseable
- Specified by:
close
in interfaceMoodleClient
-