github.com/yaegashi/msgraph.go@v0.1.4/beta/RequestActive.go (about) 1 // Code generated by msgraph.go/gen DO NOT EDIT. 2 3 package msgraph 4 5 import "context" 6 7 // ActiveDirectoryWindowsAutopilotDeploymentProfileRequestBuilder is request builder for ActiveDirectoryWindowsAutopilotDeploymentProfile 8 type ActiveDirectoryWindowsAutopilotDeploymentProfileRequestBuilder struct{ BaseRequestBuilder } 9 10 // Request returns ActiveDirectoryWindowsAutopilotDeploymentProfileRequest 11 func (b *ActiveDirectoryWindowsAutopilotDeploymentProfileRequestBuilder) Request() *ActiveDirectoryWindowsAutopilotDeploymentProfileRequest { 12 return &ActiveDirectoryWindowsAutopilotDeploymentProfileRequest{ 13 BaseRequest: BaseRequest{baseURL: b.baseURL, client: b.client}, 14 } 15 } 16 17 // ActiveDirectoryWindowsAutopilotDeploymentProfileRequest is request for ActiveDirectoryWindowsAutopilotDeploymentProfile 18 type ActiveDirectoryWindowsAutopilotDeploymentProfileRequest struct{ BaseRequest } 19 20 // Get performs GET request for ActiveDirectoryWindowsAutopilotDeploymentProfile 21 func (r *ActiveDirectoryWindowsAutopilotDeploymentProfileRequest) Get(ctx context.Context) (resObj *ActiveDirectoryWindowsAutopilotDeploymentProfile, err error) { 22 var query string 23 if r.query != nil { 24 query = "?" + r.query.Encode() 25 } 26 err = r.JSONRequest(ctx, "GET", query, nil, &resObj) 27 return 28 } 29 30 // Update performs PATCH request for ActiveDirectoryWindowsAutopilotDeploymentProfile 31 func (r *ActiveDirectoryWindowsAutopilotDeploymentProfileRequest) Update(ctx context.Context, reqObj *ActiveDirectoryWindowsAutopilotDeploymentProfile) error { 32 return r.JSONRequest(ctx, "PATCH", "", reqObj, nil) 33 } 34 35 // Delete performs DELETE request for ActiveDirectoryWindowsAutopilotDeploymentProfile 36 func (r *ActiveDirectoryWindowsAutopilotDeploymentProfileRequest) Delete(ctx context.Context) error { 37 return r.JSONRequest(ctx, "DELETE", "", nil, nil) 38 }