C# Class ElmcityUtils.BlobStorage

ファイルを表示 Open project: judell/elmcity Class Usage Examples

Public Methods

Method Description
AcquireLease ( string containername, string blobname ) : ElmcityUtils.HttpResponse
BlobStorage ( string azure_storage_account, string azure_blob_host, string azure_b64_secret ) : System
CompletedIfContainerIsGone ( BlobStorageResponse response, object o ) : bool
CompletedIfContainerIsNotBeingDeleted ( BlobStorageResponse response, Object o ) : bool
CreateContainer ( string containername, bool is_public, Hashtable headers ) : BlobStorageResponse
DeleteBlob ( string containername, string blobname ) : BlobStorageResponse
DeleteContainer ( string containername ) : BlobStorageResponse
DeserializeObjectFromBytes ( byte buffer ) : object
DeserializeObjectFromUri ( Uri uri ) : object
DictsFromBlobStorageResponse ( ElmcityUtils.HttpResponse response, string xpath, string elements, string &next_marker ) : string>>.List
DoBlobStoreRequest ( string containername, string blobname, string method, Hashtable headers, byte data, string content_type, string query_string ) : ElmcityUtils.HttpResponse
ExistsBlob ( Uri uri ) : bool
ExistsBlob ( string containername, string blobname ) : bool
ExistsContainer ( string containername ) : bool
GetAzureBlobAsString ( string container, string name ) : string
GetAzureBlobAsString ( string container, string name, bool use_cdn ) : string
GetBlob ( string containername, string blobname ) : BlobStorageResponse
GetBlobProperties ( string containername, string blobname ) : BlobStorageResponse
LegalizeContainerName ( string containername ) : string
ListBlobs ( string containername ) : BlobStorageResponse
ListBlobs ( string containername, string prefix ) : BlobStorageResponse
ListContainers ( ) : BlobStorageResponse
ListContainers ( string path ) : BlobStorageResponse
MakeAzureBlobUri ( string container, string name ) : Uri
MakeAzureBlobUri ( string container, string name, bool use_cdn ) : Uri
MakeDefaultBlobStorage ( ) : BlobStorage
MakeSafeBlobnameFromUrl ( string url ) : string
MaybeCreateContainer ( string containername, bool is_public, Hashtable headers ) : BlobStorageResponse
MaybeDeleteContainer ( string containername ) : BlobStorageResponse
PurgeBlobs ( string container, System.TimeSpan keep ) : void
PutBlob ( string containername, string blobname, Hashtable headers, byte data, string content_type ) : BlobStorageResponse
PutBlob ( string containername, string blobname, byte data ) : BlobStorageResponse
PutBlob ( string containername, string blobname, byte data, string content_type ) : BlobStorageResponse
PutBlob ( string containername, string blobname, string data ) : BlobStorageResponse
PutBlob ( string containername, string blobname, string data, string content_type ) : BlobStorageResponse
PutBlobWithLease ( string container, string blobname, Hashtable headers, byte data, string content_type ) : BlobStorageResponse
PutBlobWithLease ( string container, string blobname, Hashtable headers, string utf_string, string content_type ) : BlobStorageResponse
RetryAcquireLease ( string containername, string blobname ) : ElmcityUtils.HttpResponse
SerializeObjectToAzureBlob ( object o, string container, string blobname ) : BlobStorageResponse
WriteToAzureBlob ( BlobStorage bs, string containername, string blobname, string content_type, byte bytes ) : BlobStorageResponse

Method Details

AcquireLease() public method

public AcquireLease ( string containername, string blobname ) : ElmcityUtils.HttpResponse
containername string
blobname string
return ElmcityUtils.HttpResponse

BlobStorage() public method

public BlobStorage ( string azure_storage_account, string azure_blob_host, string azure_b64_secret ) : System
azure_storage_account string
azure_blob_host string
azure_b64_secret string
return System

CompletedIfContainerIsGone() public static method

public static CompletedIfContainerIsGone ( BlobStorageResponse response, object o ) : bool
response BlobStorageResponse
o object
return bool

CompletedIfContainerIsNotBeingDeleted() public static method

public static CompletedIfContainerIsNotBeingDeleted ( BlobStorageResponse response, Object o ) : bool
response BlobStorageResponse
o Object
return bool

CreateContainer() public method

public CreateContainer ( string containername, bool is_public, Hashtable headers ) : BlobStorageResponse
containername string
is_public bool
headers System.Collections.Hashtable
return BlobStorageResponse

DeleteBlob() public method

public DeleteBlob ( string containername, string blobname ) : BlobStorageResponse
containername string
blobname string
return BlobStorageResponse

DeleteContainer() public method

public DeleteContainer ( string containername ) : BlobStorageResponse
containername string
return BlobStorageResponse

DeserializeObjectFromBytes() public static method

public static DeserializeObjectFromBytes ( byte buffer ) : object
buffer byte
return object

DeserializeObjectFromUri() public static method

public static DeserializeObjectFromUri ( Uri uri ) : object
uri System.Uri
return object

DictsFromBlobStorageResponse() public method

public DictsFromBlobStorageResponse ( ElmcityUtils.HttpResponse response, string xpath, string elements, string &next_marker ) : string>>.List
response ElmcityUtils.HttpResponse
xpath string
elements string
next_marker string
return string>>.List

DoBlobStoreRequest() public method

public DoBlobStoreRequest ( string containername, string blobname, string method, Hashtable headers, byte data, string content_type, string query_string ) : ElmcityUtils.HttpResponse
containername string
blobname string
method string
headers System.Collections.Hashtable
data byte
content_type string
query_string string
return ElmcityUtils.HttpResponse

ExistsBlob() public static method

public static ExistsBlob ( Uri uri ) : bool
uri System.Uri
return bool

ExistsBlob() public static method

public static ExistsBlob ( string containername, string blobname ) : bool
containername string
blobname string
return bool

ExistsContainer() public static method

public static ExistsContainer ( string containername ) : bool
containername string
return bool

GetAzureBlobAsString() public static method

public static GetAzureBlobAsString ( string container, string name ) : string
container string
name string
return string

GetAzureBlobAsString() public static method

public static GetAzureBlobAsString ( string container, string name, bool use_cdn ) : string
container string
name string
use_cdn bool
return string

GetBlob() public method

public GetBlob ( string containername, string blobname ) : BlobStorageResponse
containername string
blobname string
return BlobStorageResponse

GetBlobProperties() public method

public GetBlobProperties ( string containername, string blobname ) : BlobStorageResponse
containername string
blobname string
return BlobStorageResponse

LegalizeContainerName() public static method

public static LegalizeContainerName ( string containername ) : string
containername string
return string

ListBlobs() public method

public ListBlobs ( string containername ) : BlobStorageResponse
containername string
return BlobStorageResponse

ListBlobs() public method

public ListBlobs ( string containername, string prefix ) : BlobStorageResponse
containername string
prefix string
return BlobStorageResponse

ListContainers() public method

public ListContainers ( ) : BlobStorageResponse
return BlobStorageResponse

ListContainers() public method

public ListContainers ( string path ) : BlobStorageResponse
path string
return BlobStorageResponse

MakeAzureBlobUri() public static method

public static MakeAzureBlobUri ( string container, string name ) : Uri
container string
name string
return System.Uri

MakeAzureBlobUri() public static method

public static MakeAzureBlobUri ( string container, string name, bool use_cdn ) : Uri
container string
name string
use_cdn bool
return System.Uri

MakeDefaultBlobStorage() public static method

public static MakeDefaultBlobStorage ( ) : BlobStorage
return BlobStorage

MakeSafeBlobnameFromUrl() public static method

public static MakeSafeBlobnameFromUrl ( string url ) : string
url string
return string

MaybeCreateContainer() public method

public MaybeCreateContainer ( string containername, bool is_public, Hashtable headers ) : BlobStorageResponse
containername string
is_public bool
headers System.Collections.Hashtable
return BlobStorageResponse

MaybeDeleteContainer() public method

public MaybeDeleteContainer ( string containername ) : BlobStorageResponse
containername string
return BlobStorageResponse

PurgeBlobs() public method

public PurgeBlobs ( string container, System.TimeSpan keep ) : void
container string
keep System.TimeSpan
return void

PutBlob() public method

public PutBlob ( string containername, string blobname, Hashtable headers, byte data, string content_type ) : BlobStorageResponse
containername string
blobname string
headers System.Collections.Hashtable
data byte
content_type string
return BlobStorageResponse

PutBlob() public method

public PutBlob ( string containername, string blobname, byte data ) : BlobStorageResponse
containername string
blobname string
data byte
return BlobStorageResponse

PutBlob() public method

public PutBlob ( string containername, string blobname, byte data, string content_type ) : BlobStorageResponse
containername string
blobname string
data byte
content_type string
return BlobStorageResponse

PutBlob() public method

public PutBlob ( string containername, string blobname, string data ) : BlobStorageResponse
containername string
blobname string
data string
return BlobStorageResponse

PutBlob() public method

public PutBlob ( string containername, string blobname, string data, string content_type ) : BlobStorageResponse
containername string
blobname string
data string
content_type string
return BlobStorageResponse

PutBlobWithLease() public method

public PutBlobWithLease ( string container, string blobname, Hashtable headers, byte data, string content_type ) : BlobStorageResponse
container string
blobname string
headers System.Collections.Hashtable
data byte
content_type string
return BlobStorageResponse

PutBlobWithLease() public method

public PutBlobWithLease ( string container, string blobname, Hashtable headers, string utf_string, string content_type ) : BlobStorageResponse
container string
blobname string
headers System.Collections.Hashtable
utf_string string
content_type string
return BlobStorageResponse

RetryAcquireLease() public method

public RetryAcquireLease ( string containername, string blobname ) : ElmcityUtils.HttpResponse
containername string
blobname string
return ElmcityUtils.HttpResponse

SerializeObjectToAzureBlob() public method

public SerializeObjectToAzureBlob ( object o, string container, string blobname ) : BlobStorageResponse
o object
container string
blobname string
return BlobStorageResponse

WriteToAzureBlob() public static method

public static WriteToAzureBlob ( BlobStorage bs, string containername, string blobname, string content_type, byte bytes ) : BlobStorageResponse
bs BlobStorage
containername string
blobname string
content_type string
bytes byte
return BlobStorageResponse