Documentation ¶
Index ¶
- Variables
- func InitItsiApiLimiter(concurrency int)
- func NewCache(size int) *resourceCache
- func NilTemplateMarshal(b *Base) (string, error)
- type Base
- func (b *Base) Clone() *Base
- func (b *Base) Create(ctx context.Context) (*Base, error)
- func (b *Base) Delete(ctx context.Context) error
- func (b *Base) Dump(ctx context.Context, offset, count int) ([]*Base, error)
- func (b *Base) Find(ctx context.Context) (result *Base, err error)
- func (b *Base) GetPageSize() int
- func (b *Base) Populate(raw []byte) error
- func (b *Base) PopulateRawJSON(ctx context.Context, body map[string]interface{}) error
- func (b *Base) Read(ctx context.Context) (*Base, error)
- func (b *Base) Update(ctx context.Context) error
- func (b *Base) UpdateAsync(ctx context.Context) error
- type ClientConfig
- type CollectionApi
- func (c *CollectionApi) Create(ctx context.Context) (*CollectionApi, error)
- func (c *CollectionApi) Delete(ctx context.Context) (*CollectionApi, error)
- func (c *CollectionApi) Marshal(obj interface{}) (bytes []byte, err error)
- func (c *CollectionApi) Read(ctx context.Context) (*CollectionApi, error)
- func (c *CollectionApi) SetCodeHandle(code int, instruction util.HandleCode)
- func (c *CollectionApi) Unmarshal(bytes []byte) (res interface{}, err error)
- func (c *CollectionApi) Update(ctx context.Context) (*CollectionApi, error)
- type HttpClients
- type IHttpClient
- type IHttpClients
- type RESTKeyByTFID
- type RawJson
Constants ¶
This section is empty.
Variables ¶
View Source
var Cache *resourceCache
View Source
var CollectionApiConfigs map[string]collectionApiConfig
View Source
var GenerateResourceKey = func() (string, error) {
return uuid.GenerateUUID()
}
View Source
var RestConfigs map[string]restConfig
View Source
var Verbose bool = false
Functions ¶
func InitItsiApiLimiter ¶
func InitItsiApiLimiter(concurrency int)
func NilTemplateMarshal ¶
Types ¶
type Base ¶
type Base struct { Splunk ClientConfig // key used to collect this resource via the REST API RESTKey string // Terraform Identifier TFID string RawJson RawJson Fields []string Hash string // contains filtered or unexported fields }
func NewBase ¶
func NewBase(clientConfig ClientConfig, key, id, objectType string) *Base
func (*Base) GetPageSize ¶
func (*Base) PopulateRawJSON ¶ added in v0.10.0
type ClientConfig ¶
type CollectionApi ¶
type CollectionApi struct { RESTKey string // key used to collect this resource via the REST API Collection string // Collection name App string // Collection App Owner string // Collection owner Data map[string]interface{} // Data for this object Params string // URL query string, iff provided Body []byte // Body used for this API call CustomBehaviourCodes map[int]util.HandleCode // Common unretriable errors // contains filtered or unexported fields }
func NewCollection ¶
func NewCollection(clientConfig ClientConfig, collection, app, owner, key, objectType string) *CollectionApi
func (*CollectionApi) Create ¶
func (c *CollectionApi) Create(ctx context.Context) (*CollectionApi, error)
func (*CollectionApi) Delete ¶
func (c *CollectionApi) Delete(ctx context.Context) (*CollectionApi, error)
func (*CollectionApi) Marshal ¶
func (c *CollectionApi) Marshal(obj interface{}) (bytes []byte, err error)
func (*CollectionApi) Read ¶
func (c *CollectionApi) Read(ctx context.Context) (*CollectionApi, error)
func (*CollectionApi) SetCodeHandle ¶ added in v0.10.15
func (c *CollectionApi) SetCodeHandle(code int, instruction util.HandleCode)
func (*CollectionApi) Unmarshal ¶
func (c *CollectionApi) Unmarshal(bytes []byte) (res interface{}, err error)
func (*CollectionApi) Update ¶
func (c *CollectionApi) Update(ctx context.Context) (*CollectionApi, error)
type HttpClients ¶
type HttpClients struct {
// contains filtered or unexported fields
}
func (*HttpClients) Get ¶
func (hc *HttpClients) Get(config ClientConfig) IHttpClient
type IHttpClient ¶ added in v0.8.2
type IHttpClients ¶ added in v0.8.2
type IHttpClients interface {
Get(config ClientConfig) IHttpClient
}
func InitHttpClients ¶ added in v0.8.2
func InitHttpClients() IHttpClients
type RESTKeyByTFID ¶
type RESTKeyByTFID struct {
// contains filtered or unexported fields
}
func NewRESTKeyByTFID ¶
func NewRESTKeyByTFID() *RESTKeyByTFID
func (*RESTKeyByTFID) Get ¶
func (m *RESTKeyByTFID) Get(RestInterface, ObjectType, TFID string) (RESTKey string)
func (*RESTKeyByTFID) Update ¶
func (m *RESTKeyByTFID) Update(RestInterface, ObjectType, TFID string, RESTKey string)
type RawJson ¶ added in v0.9.2
type RawJson json.RawMessage
func (RawJson) MarshalJSON ¶ added in v0.9.2
func (RawJson) ToInterfaceMap ¶ added in v0.9.2
func (*RawJson) UnmarshalJSON ¶ added in v0.9.2
Click to show internal directories.
Click to hide internal directories.