Interface CloudProfilePersistor
-
- All Known Implementing Classes:
CloudProfilePersistorFacade
,SecuredCloudProfilePersistor
public interface CloudProfilePersistor
- Author:
- Eugene Petrenko Created: 24.07.2009 18:38:10
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description CloudImageParameters
createImage(String projectId, CloudImageData imageData)
Create image with given parameters in a roject with given idCloudProfile
createProfile(String projectId, CloudProfileData data)
Creates new profile and persists it Calling this method may triggerCloudEventListener#profilesUpdated(java.util.Collection, boolean)
call.Collection<CloudImageParameters>
getImages(String projectId)
Get images based on configured project features.Collection<CloudImageParameters>
getImages(SProject project)
Get images based on configured project features.ProjectCloudIntegrationStatus
getIntegrationStatus(String projectId)
returns project's cloud integration statusCollection<CloudProfile>
getProfiles(String projectId)
Get profiles based on configured project features.Collection<CloudProfile>
getProfiles(SProject project)
Get profiles based on configured project features.boolean
hasCloudRelatedConfiguration(String projectId)
Returns true if settings of the project with given id contain cloud related configurationboolean
isConfigurable(String projectId)
boolean
isIntegrationEnabled(String projectId)
boolean
removeImage(String projectId, String profileId, String imageId)
Remove image located in given project and profile and with given idboolean
removeImageWithInternalId(String projectId, String imageInternalId)
Remove image located in given project and with given internal idboolean
removeProfile(String projectId, String profileId)
Removes profile with specified idboolean
setProfileEnabled(String projectId, String profileId, boolean isEnabled)
Marks certain cloud profile as enabled or disabled.CloudImageParameters
updateImage(String projectId, CloudImageData imageData)
Updates currently persisted image.CloudImageParameters
updateImageWithInternalId(String projectId, String imageInternalId, CloudImageData imageData)
Updates currently persisted image.CloudProfile
updateProfile(String projectId, String profileId, CloudProfileData newData)
Updates currently persisted profile.void
updateStatus(String projectId, ProjectCloudIntegrationStatus status)
Marks cloud integration as enabled or disabled in this project.
-
-
-
Method Detail
-
getProfiles
Collection<CloudProfile> getProfiles(@NotNull String projectId)
Get profiles based on configured project features.- Parameters:
project
-- Returns:
- profiles
-
getProfiles
Collection<CloudProfile> getProfiles(@NotNull SProject project)
Get profiles based on configured project features.- Parameters:
project
-- Returns:
- profiles
-
getImages
@NotNull Collection<CloudImageParameters> getImages(@NotNull String projectId)
Get images based on configured project features. Both - configured in profiles and inherited from parent projects.- Parameters:
project
-- Returns:
- all cloud images (own and inherited)
-
getImages
@NotNull Collection<CloudImageParameters> getImages(@NotNull SProject project)
Get images based on configured project features. Both - configured in profiles and inherited from parent projects.- Parameters:
project
-- Returns:
- all cloud images (own and inherited)
-
createImage
@NotNull CloudImageParameters createImage(@NotNull String projectId, @NotNull CloudImageData imageData)
Create image with given parameters in a roject with given id- Parameters:
projectId
-imageParameters
-- Returns:
- Newly created image
-
updateImage
@NotNull CloudImageParameters updateImage(@NotNull String projectId, @NotNull CloudImageData imageData)
Updates currently persisted image.- Parameters:
projectId
-profileId
-imageInternalId
-newData
- new values
-
updateImageWithInternalId
@NotNull CloudImageParameters updateImageWithInternalId(@NotNull String projectId, @NotNull String imageInternalId, @NotNull CloudImageData imageData)
Updates currently persisted image.- Parameters:
projectId
-profileId
-imageInternalId
-newData
- new values
-
removeImage
boolean removeImage(@NotNull String projectId, @NotNull String profileId, @NotNull String imageId)
Remove image located in given project and profile and with given id- Parameters:
projectId
-profileId
-imageId
-- Returns:
- true if image was actually removed, False otherwise
-
removeImageWithInternalId
boolean removeImageWithInternalId(@NotNull String projectId, @NotNull String imageInternalId)
Remove image located in given project and with given internal id- Parameters:
projectId
-imageInternalId
-- Returns:
- true if image was actually removed, False otherwise
-
isIntegrationEnabled
boolean isIntegrationEnabled(@NotNull String projectId)
- Returns:
- true if integration is enabled in a project considering project hierarchy
-
getIntegrationStatus
@NotNull ProjectCloudIntegrationStatus getIntegrationStatus(@NotNull String projectId)
returns project's cloud integration status- Parameters:
projectId
-- Returns:
-
isConfigurable
boolean isConfigurable(@NotNull String projectId)
- Returns:
- true if cloud configuration is available in a project considering project hierarchy
-
hasCloudRelatedConfiguration
boolean hasCloudRelatedConfiguration(@NotNull String projectId)
Returns true if settings of the project with given id contain cloud related configuration- Parameters:
projectId
-- Returns:
-
createProfile
@NotNull CloudProfile createProfile(@NotNull String projectId, @NotNull CloudProfileData data)
Creates new profile and persists it Calling this method may triggerCloudEventListener#profilesUpdated(java.util.Collection, boolean)
call.- Parameters:
data
- profile info to save
-
removeProfile
boolean removeProfile(@NotNull String projectId, @NotNull String profileId)
Removes profile with specified id- Parameters:
profileId
- profileId to remove- Returns:
- True if profile was actually removed, False otherwise
-
updateProfile
@NotNull CloudProfile updateProfile(@NotNull String projectId, @NotNull String profileId, @NotNull CloudProfileData newData)
Updates currently persisted profile.- Parameters:
profileId
- profile id to updatenewData
- new values
-
updateStatus
void updateStatus(@NotNull String projectId, ProjectCloudIntegrationStatus status)
Marks cloud integration as enabled or disabled in this project.- Parameters:
status
- false to disable could integration
-
-