jobstream

package
v0.20240731.1170959 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Jul 31, 2024 License: MPL-2.0 Imports: 13 Imported by: 1

README

github.com/hashicorp/go-azure-sdk/resource-manager/automation/2015-10-31/jobstream Documentation

The jobstream SDK allows for interaction with the Azure Resource Manager Service automation (API Version 2015-10-31).

This readme covers example usages, but further information on using this SDK can be found in the project root.

Import Path

import "github.com/hashicorp/go-azure-sdk/resource-manager/automation/2015-10-31/jobstream"

Client Initialization

client := jobstream.NewJobStreamClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer

Example Usage: JobStreamClient.Get

ctx := context.TODO()
id := jobstream.NewStreamID("12345678-1234-9876-4563-123456789012", "example-resource-group", "automationAccountValue", "jobIdValue", "jobStreamIdValue")

read, err := client.Get(ctx, id)
if err != nil {
	// handle the error
}
if model := read.Model; model != nil {
	// do something with the model/response object
}

Example Usage: JobStreamClient.ListByJob

ctx := context.TODO()
id := jobstream.NewJobID("12345678-1234-9876-4563-123456789012", "example-resource-group", "automationAccountValue", "jobIdValue")

// alternatively `client.ListByJob(ctx, id, jobstream.DefaultListByJobOperationOptions())` can be used to do batched pagination
items, err := client.ListByJobComplete(ctx, id, jobstream.DefaultListByJobOperationOptions())
if err != nil {
	// handle the error
}
for _, item := range items {
	// do something
}

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func PossibleValuesForJobStreamType

func PossibleValuesForJobStreamType() []string

func ValidateJobID

func ValidateJobID(input interface{}, key string) (warnings []string, errors []error)

ValidateJobID checks that 'input' can be parsed as a Job ID

func ValidateStreamID

func ValidateStreamID(input interface{}, key string) (warnings []string, errors []error)

ValidateStreamID checks that 'input' can be parsed as a Stream ID

Types

type GetOperationResponse

type GetOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *JobStream
}

type JobId

type JobId struct {
	SubscriptionId        string
	ResourceGroupName     string
	AutomationAccountName string
	JobId                 string
}

JobId is a struct representing the Resource ID for a Job

func NewJobID

func NewJobID(subscriptionId string, resourceGroupName string, automationAccountName string, jobId string) JobId

NewJobID returns a new JobId struct

func ParseJobID

func ParseJobID(input string) (*JobId, error)

ParseJobID parses 'input' into a JobId

func ParseJobIDInsensitively

func ParseJobIDInsensitively(input string) (*JobId, error)

ParseJobIDInsensitively parses 'input' case-insensitively into a JobId note: this method should only be used for API response data and not user input

func (*JobId) FromParseResult

func (id *JobId) FromParseResult(input resourceids.ParseResult) error

func (JobId) ID

func (id JobId) ID() string

ID returns the formatted Job ID

func (JobId) Segments

func (id JobId) Segments() []resourceids.Segment

Segments returns a slice of Resource ID Segments which comprise this Job ID

func (JobId) String

func (id JobId) String() string

String returns a human-readable description of this Job ID

type JobStream

type JobStream struct {
	Id         *string              `json:"id,omitempty"`
	Properties *JobStreamProperties `json:"properties,omitempty"`
}

type JobStreamClient

type JobStreamClient struct {
	Client *resourcemanager.Client
}

func NewJobStreamClientWithBaseURI

func NewJobStreamClientWithBaseURI(sdkApi sdkEnv.Api) (*JobStreamClient, error)

func (JobStreamClient) Get

func (c JobStreamClient) Get(ctx context.Context, id StreamId) (result GetOperationResponse, err error)

Get ...

func (JobStreamClient) ListByJob

ListByJob ...

func (JobStreamClient) ListByJobComplete

ListByJobComplete retrieves all the results into a single object

func (JobStreamClient) ListByJobCompleteMatchingPredicate

func (c JobStreamClient) ListByJobCompleteMatchingPredicate(ctx context.Context, id JobId, options ListByJobOperationOptions, predicate JobStreamOperationPredicate) (result ListByJobCompleteResult, err error)

ListByJobCompleteMatchingPredicate retrieves all the results and then applies the predicate

type JobStreamOperationPredicate

type JobStreamOperationPredicate struct {
	Id *string
}

func (JobStreamOperationPredicate) Matches

func (p JobStreamOperationPredicate) Matches(input JobStream) bool

type JobStreamProperties

type JobStreamProperties struct {
	JobStreamId *string                 `json:"jobStreamId,omitempty"`
	StreamText  *string                 `json:"streamText,omitempty"`
	StreamType  *JobStreamType          `json:"streamType,omitempty"`
	Summary     *string                 `json:"summary,omitempty"`
	Time        *string                 `json:"time,omitempty"`
	Value       *map[string]interface{} `json:"value,omitempty"`
}

func (*JobStreamProperties) GetTimeAsTime

func (o *JobStreamProperties) GetTimeAsTime() (*time.Time, error)

func (*JobStreamProperties) SetTimeAsTime

func (o *JobStreamProperties) SetTimeAsTime(input time.Time)

type JobStreamType

type JobStreamType string
const (
	JobStreamTypeAny      JobStreamType = "Any"
	JobStreamTypeDebug    JobStreamType = "Debug"
	JobStreamTypeError    JobStreamType = "Error"
	JobStreamTypeOutput   JobStreamType = "Output"
	JobStreamTypeProgress JobStreamType = "Progress"
	JobStreamTypeVerbose  JobStreamType = "Verbose"
	JobStreamTypeWarning  JobStreamType = "Warning"
)

func (*JobStreamType) UnmarshalJSON added in v0.20240209.1164150

func (s *JobStreamType) UnmarshalJSON(bytes []byte) error

type ListByJobCompleteResult

type ListByJobCompleteResult struct {
	LatestHttpResponse *http.Response
	Items              []JobStream
}

type ListByJobCustomPager added in v0.20240628.1153531

type ListByJobCustomPager struct {
	NextLink *odata.Link `json:"nextLink"`
}
func (p *ListByJobCustomPager) NextPageLink() *odata.Link

type ListByJobOperationOptions

type ListByJobOperationOptions struct {
	Filter *string
}

func DefaultListByJobOperationOptions

func DefaultListByJobOperationOptions() ListByJobOperationOptions

func (ListByJobOperationOptions) ToHeaders added in v0.20240209.1164150

func (o ListByJobOperationOptions) ToHeaders() *client.Headers

func (ListByJobOperationOptions) ToOData added in v0.20240209.1164150

func (o ListByJobOperationOptions) ToOData() *odata.Query

func (ListByJobOperationOptions) ToQuery added in v0.20240209.1164150

type ListByJobOperationResponse

type ListByJobOperationResponse struct {
	HttpResponse *http.Response
	OData        *odata.OData
	Model        *[]JobStream
}

type StreamId

type StreamId struct {
	SubscriptionId        string
	ResourceGroupName     string
	AutomationAccountName string
	JobId                 string
	JobStreamId           string
}

StreamId is a struct representing the Resource ID for a Stream

func NewStreamID

func NewStreamID(subscriptionId string, resourceGroupName string, automationAccountName string, jobId string, jobStreamId string) StreamId

NewStreamID returns a new StreamId struct

func ParseStreamID

func ParseStreamID(input string) (*StreamId, error)

ParseStreamID parses 'input' into a StreamId

func ParseStreamIDInsensitively

func ParseStreamIDInsensitively(input string) (*StreamId, error)

ParseStreamIDInsensitively parses 'input' case-insensitively into a StreamId note: this method should only be used for API response data and not user input

func (*StreamId) FromParseResult

func (id *StreamId) FromParseResult(input resourceids.ParseResult) error

func (StreamId) ID

func (id StreamId) ID() string

ID returns the formatted Stream ID

func (StreamId) Segments

func (id StreamId) Segments() []resourceids.Segment

Segments returns a slice of Resource ID Segments which comprise this Stream ID

func (StreamId) String

func (id StreamId) String() string

String returns a human-readable description of this Stream ID

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL