[#17] Client: Add extra parameter
API methods' parameters types with optional session, polling settings, xHeaders etc. and corresponding handlers have been added Signed-off-by: Pavel Gross <p.gross@yadro.com>
This commit is contained in:
parent
00a1e9412f
commit
7b9c19f37c
42 changed files with 1054 additions and 386 deletions
|
@ -13,6 +13,12 @@ public static class ObjectExtensions
|
|||
return obj;
|
||||
}
|
||||
|
||||
public static FrostFsObject SetPayload(this FrostFsObject obj, byte[] bytes)
|
||||
{
|
||||
obj.Payload = bytes;
|
||||
return obj;
|
||||
}
|
||||
|
||||
public static FrostFsObject AddAttribute(this FrostFsObject obj, string key, string value)
|
||||
{
|
||||
obj.AddAttribute(new ObjectAttribute(key, value));
|
||||
|
@ -45,9 +51,6 @@ public static class ObjectExtensions
|
|||
|
||||
public static FrostFsObject CalculateObjectId(this FrostFsObject obj)
|
||||
{
|
||||
if (obj.Payload == null)
|
||||
throw new MissingFieldException("Payload cannot be null");
|
||||
|
||||
if (obj.Header == null)
|
||||
throw new MissingFieldException("Header cannot be null");
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue