README ¶
github.com/hashicorp/go-azure-sdk/resource-manager/advisor/2022-10-01/prediction
Documentation
The prediction
SDK allows for interaction with the Azure Resource Manager Service advisor
(API Version 2022-10-01
).
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/advisor/2022-10-01/prediction"
Client Initialization
client := prediction.NewPredictionClientWithBaseURI("https://management.azure.com")
client.Client.Authorizer = authorizer
Example Usage: PredictionClient.Predict
ctx := context.TODO()
id := prediction.NewSubscriptionID("12345678-1234-9876-4563-123456789012")
payload := prediction.PredictionRequest{
// ...
}
read, err := client.Predict(ctx, id, payload)
if err != nil {
// handle the error
}
if model := read.Model; model != nil {
// do something with the model/response object
}
Documentation ¶
Index ¶
- func PossibleValuesForCategory() []string
- func PossibleValuesForImpact() []string
- func PossibleValuesForPredictionType() []string
- type Category
- type Impact
- type PredictOperationResponse
- type PredictionClient
- type PredictionRequest
- type PredictionRequestProperties
- type PredictionResponse
- type PredictionResponseProperties
- type PredictionType
- type ShortDescription
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func PossibleValuesForCategory ¶
func PossibleValuesForCategory() []string
func PossibleValuesForImpact ¶
func PossibleValuesForImpact() []string
func PossibleValuesForPredictionType ¶
func PossibleValuesForPredictionType() []string
Types ¶
type PredictOperationResponse ¶
type PredictOperationResponse struct { HttpResponse *http.Response Model *PredictionResponse }
type PredictionClient ¶
func NewPredictionClientWithBaseURI ¶
func NewPredictionClientWithBaseURI(endpoint string) PredictionClient
func (PredictionClient) Predict ¶
func (c PredictionClient) Predict(ctx context.Context, id commonids.SubscriptionId, input PredictionRequest) (result PredictOperationResponse, err error)
Predict ...
type PredictionRequest ¶
type PredictionRequest struct {
Properties *PredictionRequestProperties `json:"properties,omitempty"`
}
type PredictionRequestProperties ¶
type PredictionRequestProperties struct { ExtendedProperties *interface{} `json:"extendedProperties,omitempty"` PredictionType *PredictionType `json:"predictionType,omitempty"` }
type PredictionResponse ¶
type PredictionResponse struct {
Properties *PredictionResponseProperties `json:"properties,omitempty"`
}
type PredictionResponseProperties ¶
type PredictionResponseProperties struct { Category *Category `json:"category,omitempty"` ExtendedProperties *interface{} `json:"extendedProperties,omitempty"` Impact *Impact `json:"impact,omitempty"` ImpactedField *string `json:"impactedField,omitempty"` LastUpdated *string `json:"lastUpdated,omitempty"` PredictionType *PredictionType `json:"predictionType,omitempty"` ShortDescription *ShortDescription `json:"shortDescription,omitempty"` }
func (*PredictionResponseProperties) GetLastUpdatedAsTime ¶
func (o *PredictionResponseProperties) GetLastUpdatedAsTime() (*time.Time, error)
func (*PredictionResponseProperties) SetLastUpdatedAsTime ¶
func (o *PredictionResponseProperties) SetLastUpdatedAsTime(input time.Time)
type PredictionType ¶
type PredictionType string
const (
PredictionTypePredictiveRightsizing PredictionType = "PredictiveRightsizing"
)
type ShortDescription ¶
Click to show internal directories.
Click to hide internal directories.