org.jclouds.cloudstack.features
Interface SnapshotApi


public interface SnapshotApi

Provides synchronous access to CloudStack Snapshot features.

See Also:
http://download.cloud.com/releases/2.2.0/api/TOC_User.html

Method Summary
 AsyncCreateResponse createSnapshot(String volumeId, CreateSnapshotOptions... options)
          Creates an instant snapshot of a volume.
 SnapshotPolicy createSnapshotPolicy(SnapshotPolicySchedule schedule, String numberToRetain, String timezone, String volumeId)
          Creates a snapshot policy for the account.
 void deleteSnapshot(String id)
          Deletes a snapshot of a disk volume.
 void deleteSnapshotPolicies(Iterable<String> id)
          Deletes snapshot policies for the account.
 void deleteSnapshotPolicy(String id)
          Deletes a snapshot policy for the account.
 Snapshot getSnapshot(String id)
          Gets a snapshot by its ID.
 Set<SnapshotPolicy> listSnapshotPolicies(String volumeId, ListSnapshotPoliciesOptions... options)
          Lists snapshot policies.
 Set<Snapshot> listSnapshots(ListSnapshotsOptions... options)
          Lists all available snapshots for the account, matching the query described by the options.
 

Method Detail

createSnapshot

@Named(value="createSnapshot")
AsyncCreateResponse createSnapshot(String volumeId,
                                         CreateSnapshotOptions... options)
Creates an instant snapshot of a volume.

Parameters:
volumeId - The ID of the disk volume
options - optional arguments
Returns:
an asynchronous job structure

listSnapshots

@Named(value="listSnapshots")
Set<Snapshot> listSnapshots(ListSnapshotsOptions... options)
Lists all available snapshots for the account, matching the query described by the options.

Parameters:
options - optional arguments
Returns:
the snapshots matching the query

getSnapshot

@Named(value="listSnapshots")
Snapshot getSnapshot(String id)
Gets a snapshot by its ID.

Parameters:
id - the snapshot ID
Returns:
the snapshot with the requested ID

deleteSnapshot

@Named(value="deleteSnapshot")
void deleteSnapshot(String id)
Deletes a snapshot of a disk volume.

Parameters:
id - The ID of the snapshot

createSnapshotPolicy

@Named(value="createSnapshotPolicy")
SnapshotPolicy createSnapshotPolicy(SnapshotPolicySchedule schedule,
                                          String numberToRetain,
                                          String timezone,
                                          String volumeId)
Creates a snapshot policy for the account.

Parameters:
schedule - how to schedule snapshots
numberToRetain - maximum number of snapshots to retain
timezone - Specifies a timezone for this command. For more information on the timezone parameter, see Time Zone Format.
volumeId - the ID of the disk volume
Returns:
the newly-created snapshot policy

deleteSnapshotPolicy

@Named(value="deleteSnapshotPolicies")
void deleteSnapshotPolicy(String id)
Deletes a snapshot policy for the account.

Parameters:
id - The ID of the snapshot policy

deleteSnapshotPolicies

@Named(value="deleteSnapshotPolicies")
void deleteSnapshotPolicies(Iterable<String> id)
Deletes snapshot policies for the account.

Parameters:
id - IDs of snapshot policies

listSnapshotPolicies

@Named(value="listSnapshotPolicies")
Set<SnapshotPolicy> listSnapshotPolicies(String volumeId,
                                               ListSnapshotPoliciesOptions... options)
Lists snapshot policies.

Parameters:
volumeId - the ID of the disk volume
options - optional arguments
Returns:
the snapshot policies matching the query


Copyright © 2009-2014 The Apache Software Foundation. All Rights Reserved.