Class ResourceGovernor
java.lang.Object
net.finmath.smartcontract.valuation.service.utils.ResourceGovernor
Class that provides all resource access to the rest of the services.
-
Nested Class Summary
-
Constructor Summary
ConstructorDescriptionResourceGovernor
(org.springframework.core.io.support.ResourcePatternResolver resourcePatternResolver) -
Method Summary
Modifier and TypeMethodDescriptionorg.springframework.core.io.Resource
getActiveDatasetAsResourceInReadMode
(String username) org.springframework.core.io.WritableResource
getActiveDatasetAsResourceInWriteMode
(String username) org.springframework.core.io.Resource
org.springframework.core.io.Resource
org.springframework.core.io.WritableResource
org.springframework.core.io.Resource
getReadableResource
(String username, ResourceGovernor.RoleFolders roleFolder, String filename) org.springframework.core.io.Resource
org.springframework.core.io.WritableResource
getWritableResource
(String username, ResourceGovernor.RoleFolders roleFolder, String filename) org.springframework.core.io.Resource[]
listContentsOfUserFolder
(String username, ResourceGovernor.RoleFolders roleFolder)
-
Constructor Details
-
ResourceGovernor
public ResourceGovernor(org.springframework.core.io.support.ResourcePatternResolver resourcePatternResolver)
-
-
Method Details
-
getActiveDatasetAsResourceInReadMode
-
getActiveDatasetAsResourceInWriteMode
public org.springframework.core.io.WritableResource getActiveDatasetAsResourceInWriteMode(String username) -
getImportCandidateAsResourceInReadMode
public org.springframework.core.io.Resource getImportCandidateAsResourceInReadMode() -
getImportCandidateAsResourceInWriteMode
public org.springframework.core.io.WritableResource getImportCandidateAsResourceInWriteMode() -
getRefinitivPropertiesAsResourceInReadMode
public org.springframework.core.io.Resource getRefinitivPropertiesAsResourceInReadMode() -
getDatabasePropertiesAsResourceInReadMode
public org.springframework.core.io.Resource getDatabasePropertiesAsResourceInReadMode() -
getReadableResource
public org.springframework.core.io.Resource getReadableResource(String username, ResourceGovernor.RoleFolders roleFolder, String filename) -
getWritableResource
public org.springframework.core.io.WritableResource getWritableResource(String username, ResourceGovernor.RoleFolders roleFolder, String filename) -
listContentsOfUserFolder
public org.springframework.core.io.Resource[] listContentsOfUserFolder(String username, ResourceGovernor.RoleFolders roleFolder) throws IOException - Throws:
IOException
-