C# Client Library
A C# Client Library for the AnalyzeRe REST API
Loading...
Searching...
No Matches
AnalyzeRe.APITypes.CommandSubResource Class Reference

Describes a command sub-resource available off a resource which can be POSTed to with no data to invoke some sort of action. More...

Public Member Functions

 CommandSubResource (IEndpoint owner, string relativePath)
 Defines a new endpoint off of another.
 
IRestResponse GET (int? timeout=null, bool throwOnError=true, IEnumerable< Parameter > requestParameters=null)
 Performs an empty GET at this endpoint (executing the command). Throws an APIRequestException if the response is not successful.
 
IRestResponse POST (int? timeout=null, bool throwOnError=true, IEnumerable< Parameter > requestParameters=null)
 Performs an empty POST at this endpoint (executing the command). Throws an APIRequestException if the response is not successful.
 
void ValidateOwnerHasId ()
 Verifies the owner exists and has been POSTed, ensuring that it is safe to invoke actions on this SubResourceEndpoint.
 

Properties

IEndpoint Owner [get]
 The endpoint off of which this sub-endpoint exists.
 
string Path [get]
 The relative path to this endpoint from the root server URL.
 
string RelativePathFromOwner [get]
 The relative path to this endpoint from its owner.
 

Detailed Description

Describes a command sub-resource available off a resource which can be POSTed to with no data to invoke some sort of action.

Definition at line 8 of file CommandSubResource.cs.

Inheritance diagram for AnalyzeRe.APITypes.CommandSubResource:
AnalyzeRe.APITypes.SubResourceEndpoint AnalyzeRe.APITypes.IEndpoint

Constructor & Destructor Documentation

◆ CommandSubResource()

AnalyzeRe.APITypes.CommandSubResource.CommandSubResource ( IEndpoint  owner,
string  relativePath 
)
inline

Defines a new endpoint off of another.

Parameters
ownerThe endpoint which owns this one.
relativePathThe relative path to endpoint from its owner.

Definition at line 14 of file CommandSubResource.cs.

Member Function Documentation

◆ GET()

IRestResponse AnalyzeRe.APITypes.CommandSubResource.GET ( int timeout = null,
bool  throwOnError = true,
IEnumerable< Parameter requestParameters = null 
)
inline

Performs an empty GET at this endpoint (executing the command). Throws an APIRequestException if the response is not successful.

Parameters
timeout(Optional) The timeout before the request fails.
throwOnError(Optional) Set to false to disable throwing an APIRequestException if the response is an error.
requestParametersOptional - Additional parameters to include in the request.
Returns
The IRestResponse if the request was successful.

Definition at line 40 of file CommandSubResource.cs.

◆ POST()

IRestResponse AnalyzeRe.APITypes.CommandSubResource.POST ( int timeout = null,
bool  throwOnError = true,
IEnumerable< Parameter requestParameters = null 
)
inline

Performs an empty POST at this endpoint (executing the command). Throws an APIRequestException if the response is not successful.

Parameters
timeout(Optional) The timeout before the request fails.
throwOnError(Optional) Set to false to disable throwing an APIRequestException if the response is an error.
requestParametersOptional - Additional parameters to include in the request.
Returns

The IRestResponse if the request was successful.

The IRestResponse if the request was successful.

Definition at line 27 of file CommandSubResource.cs.

◆ ValidateOwnerHasId()

void AnalyzeRe.APITypes.SubResourceEndpoint.ValidateOwnerHasId ( )
inlineinherited

Verifies the owner exists and has been POSTed, ensuring that it is safe to invoke actions on this SubResourceEndpoint.

Exceptions
ArgumentExceptionIf the resource's id is null or empty.

Definition at line 34 of file SubResourceEndpoint.cs.

Property Documentation

◆ Owner

IEndpoint AnalyzeRe.APITypes.SubResourceEndpoint.Owner
getinherited

The endpoint off of which this sub-endpoint exists.

Definition at line 12 of file SubResourceEndpoint.cs.

◆ Path

string AnalyzeRe.APITypes.SubResourceEndpoint.Path
getinherited

The relative path to this endpoint from the root server URL.

The relative path to this endpoint from the root URL.

Implements AnalyzeRe.APITypes.IEndpoint.

Definition at line 19 of file SubResourceEndpoint.cs.

◆ RelativePathFromOwner

string AnalyzeRe.APITypes.SubResourceEndpoint.RelativePathFromOwner
getinherited

The relative path to this endpoint from its owner.

Definition at line 15 of file SubResourceEndpoint.cs.


The documentation for this class was generated from the following file: