/
githubmirror
/
origin
Обзор
Документация
Войти
/
githubmirror
/
origin
Код
Запросы
0
Пакеты
0
Релизы
0
Аналитика
Безопасность
main
vendor/github.com/microsoftgraph/msgraph-sdk-go/models/resource_visualization.go
412 строк
15 KB
Justin Pierce
Add compat_otp package with openshift-tests-private (OTP) util implementations
11 авг 2025, 18:00
11 авг 2025, 18:00
80ac5c1
Код
Авторство
О чём код?
// Code generated by Microsoft Kiota - DO NOT EDIT. // Changes may cause incorrect behavior and will be lost if the code is regenerated. package models import ( i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91 "github.com/microsoft/kiota-abstractions-go/serialization" ie8677ce2c7e1b4c22e9c3827ecd078d41185424dd9eeb92b7d971ed2d49a392e "github.com/microsoft/kiota-abstractions-go/store" ) type ResourceVisualization struct { // Stores model information. backingStore ie8677ce2c7e1b4c22e9c3827ecd078d41185424dd9eeb92b7d971ed2d49a392e.BackingStore } // NewResourceVisualization instantiates a new ResourceVisualization and sets the default values. func NewResourceVisualization()(*ResourceVisualization) { m := &ResourceVisualization{ } m.backingStore = ie8677ce2c7e1b4c22e9c3827ecd078d41185424dd9eeb92b7d971ed2d49a392e.BackingStoreFactoryInstance(); m.SetAdditionalData(make(map[string]any)) return m } // CreateResourceVisualizationFromDiscriminatorValue creates a new instance of the appropriate class based on discriminator value // returns a Parsable when successful func CreateResourceVisualizationFromDiscriminatorValue(parseNode i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable, error) { return NewResourceVisualization(), nil } // GetAdditionalData gets the AdditionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. // returns a map[string]any when successful func (m *ResourceVisualization) GetAdditionalData()(map[string]any) { val , err := m.backingStore.Get("additionalData") if err != nil { panic(err) } if val == nil { var value = make(map[string]any); m.SetAdditionalData(value); } return val.(map[string]any) } // GetBackingStore gets the BackingStore property value. Stores model information. // returns a BackingStore when successful func (m *ResourceVisualization) GetBackingStore()(ie8677ce2c7e1b4c22e9c3827ecd078d41185424dd9eeb92b7d971ed2d49a392e.BackingStore) { return m.backingStore } // GetContainerDisplayName gets the containerDisplayName property value. A string describing where the item is stored. For example, the name of a SharePoint site or the user name identifying the owner of the OneDrive storing the item. // returns a *string when successful func (m *ResourceVisualization) GetContainerDisplayName()(*string) { val, err := m.GetBackingStore().Get("containerDisplayName") if err != nil { panic(err) } if val != nil { return val.(*string) } return nil } // GetContainerType gets the containerType property value. Can be used for filtering by the type of container in which the file is stored. Such as Site or OneDriveBusiness. // returns a *string when successful func (m *ResourceVisualization) GetContainerType()(*string) { val, err := m.GetBackingStore().Get("containerType") if err != nil { panic(err) } if val != nil { return val.(*string) } return nil } // GetContainerWebUrl gets the containerWebUrl property value. A path leading to the folder in which the item is stored. // returns a *string when successful func (m *ResourceVisualization) GetContainerWebUrl()(*string) { val, err := m.GetBackingStore().Get("containerWebUrl") if err != nil { panic(err) } if val != nil { return val.(*string) } return nil } // GetFieldDeserializers the deserialization information for the current model // returns a map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error) when successful func (m *ResourceVisualization) GetFieldDeserializers()(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error)) { res := make(map[string]func(i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode)(error)) res["containerDisplayName"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error { val, err := n.GetStringValue() if err != nil { return err } if val != nil { m.SetContainerDisplayName(val) } return nil } res["containerType"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error { val, err := n.GetStringValue() if err != nil { return err } if val != nil { m.SetContainerType(val) } return nil } res["containerWebUrl"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error { val, err := n.GetStringValue() if err != nil { return err } if val != nil { m.SetContainerWebUrl(val) } return nil } res["mediaType"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error { val, err := n.GetStringValue() if err != nil { return err } if val != nil { m.SetMediaType(val) } return nil } res["@odata.type"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error { val, err := n.GetStringValue() if err != nil { return err } if val != nil { m.SetOdataType(val) } return nil } res["previewImageUrl"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error { val, err := n.GetStringValue() if err != nil { return err } if val != nil { m.SetPreviewImageUrl(val) } return nil } res["previewText"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error { val, err := n.GetStringValue() if err != nil { return err } if val != nil { m.SetPreviewText(val) } return nil } res["title"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error { val, err := n.GetStringValue() if err != nil { return err } if val != nil { m.SetTitle(val) } return nil } res["type"] = func (n i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.ParseNode) error { val, err := n.GetStringValue() if err != nil { return err } if val != nil { m.SetTypeEscaped(val) } return nil } return res } // GetMediaType gets the mediaType property value. The item's media type. Can be used for filtering for a specific type of file based on supported IANA Media Mime Types. Not all Media Mime Types are supported. // returns a *string when successful func (m *ResourceVisualization) GetMediaType()(*string) { val, err := m.GetBackingStore().Get("mediaType") if err != nil { panic(err) } if val != nil { return val.(*string) } return nil } // GetOdataType gets the @odata.type property value. The OdataType property // returns a *string when successful func (m *ResourceVisualization) GetOdataType()(*string) { val, err := m.GetBackingStore().Get("odataType") if err != nil { panic(err) } if val != nil { return val.(*string) } return nil } // GetPreviewImageUrl gets the previewImageUrl property value. A URL leading to the preview image for the item. // returns a *string when successful func (m *ResourceVisualization) GetPreviewImageUrl()(*string) { val, err := m.GetBackingStore().Get("previewImageUrl") if err != nil { panic(err) } if val != nil { return val.(*string) } return nil } // GetPreviewText gets the previewText property value. A preview text for the item. // returns a *string when successful func (m *ResourceVisualization) GetPreviewText()(*string) { val, err := m.GetBackingStore().Get("previewText") if err != nil { panic(err) } if val != nil { return val.(*string) } return nil } // GetTitle gets the title property value. The item's title text. // returns a *string when successful func (m *ResourceVisualization) GetTitle()(*string) { val, err := m.GetBackingStore().Get("title") if err != nil { panic(err) } if val != nil { return val.(*string) } return nil } // GetTypeEscaped gets the type property value. The item's media type. Can be used for filtering for a specific file based on a specific type. See the section Type property values for supported types. // returns a *string when successful func (m *ResourceVisualization) GetTypeEscaped()(*string) { val, err := m.GetBackingStore().Get("typeEscaped") if err != nil { panic(err) } if val != nil { return val.(*string) } return nil } // Serialize serializes information the current object func (m *ResourceVisualization) Serialize(writer i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.SerializationWriter)(error) { { err := writer.WriteStringValue("containerDisplayName", m.GetContainerDisplayName()) if err != nil { return err } } { err := writer.WriteStringValue("containerType", m.GetContainerType()) if err != nil { return err } } { err := writer.WriteStringValue("containerWebUrl", m.GetContainerWebUrl()) if err != nil { return err } } { err := writer.WriteStringValue("mediaType", m.GetMediaType()) if err != nil { return err } } { err := writer.WriteStringValue("@odata.type", m.GetOdataType()) if err != nil { return err } } { err := writer.WriteStringValue("previewImageUrl", m.GetPreviewImageUrl()) if err != nil { return err } } { err := writer.WriteStringValue("previewText", m.GetPreviewText()) if err != nil { return err } } { err := writer.WriteStringValue("title", m.GetTitle()) if err != nil { return err } } { err := writer.WriteStringValue("type", m.GetTypeEscaped()) if err != nil { return err } } { err := writer.WriteAdditionalData(m.GetAdditionalData()) if err != nil { return err } } return nil } // SetAdditionalData sets the AdditionalData property value. Stores additional data not described in the OpenAPI description found when deserializing. Can be used for serialization as well. func (m *ResourceVisualization) SetAdditionalData(value map[string]any)() { err := m.GetBackingStore().Set("additionalData", value) if err != nil { panic(err) } } // SetBackingStore sets the BackingStore property value. Stores model information. func (m *ResourceVisualization) SetBackingStore(value ie8677ce2c7e1b4c22e9c3827ecd078d41185424dd9eeb92b7d971ed2d49a392e.BackingStore)() { m.backingStore = value } // SetContainerDisplayName sets the containerDisplayName property value. A string describing where the item is stored. For example, the name of a SharePoint site or the user name identifying the owner of the OneDrive storing the item. func (m *ResourceVisualization) SetContainerDisplayName(value *string)() { err := m.GetBackingStore().Set("containerDisplayName", value) if err != nil { panic(err) } } // SetContainerType sets the containerType property value. Can be used for filtering by the type of container in which the file is stored. Such as Site or OneDriveBusiness. func (m *ResourceVisualization) SetContainerType(value *string)() { err := m.GetBackingStore().Set("containerType", value) if err != nil { panic(err) } } // SetContainerWebUrl sets the containerWebUrl property value. A path leading to the folder in which the item is stored. func (m *ResourceVisualization) SetContainerWebUrl(value *string)() { err := m.GetBackingStore().Set("containerWebUrl", value) if err != nil { panic(err) } } // SetMediaType sets the mediaType property value. The item's media type. Can be used for filtering for a specific type of file based on supported IANA Media Mime Types. Not all Media Mime Types are supported. func (m *ResourceVisualization) SetMediaType(value *string)() { err := m.GetBackingStore().Set("mediaType", value) if err != nil { panic(err) } } // SetOdataType sets the @odata.type property value. The OdataType property func (m *ResourceVisualization) SetOdataType(value *string)() { err := m.GetBackingStore().Set("odataType", value) if err != nil { panic(err) } } // SetPreviewImageUrl sets the previewImageUrl property value. A URL leading to the preview image for the item. func (m *ResourceVisualization) SetPreviewImageUrl(value *string)() { err := m.GetBackingStore().Set("previewImageUrl", value) if err != nil { panic(err) } } // SetPreviewText sets the previewText property value. A preview text for the item. func (m *ResourceVisualization) SetPreviewText(value *string)() { err := m.GetBackingStore().Set("previewText", value) if err != nil { panic(err) } } // SetTitle sets the title property value. The item's title text. func (m *ResourceVisualization) SetTitle(value *string)() { err := m.GetBackingStore().Set("title", value) if err != nil { panic(err) } } // SetTypeEscaped sets the type property value. The item's media type. Can be used for filtering for a specific file based on a specific type. See the section Type property values for supported types. func (m *ResourceVisualization) SetTypeEscaped(value *string)() { err := m.GetBackingStore().Set("typeEscaped", value) if err != nil { panic(err) } } type ResourceVisualizationable interface { i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.AdditionalDataHolder ie8677ce2c7e1b4c22e9c3827ecd078d41185424dd9eeb92b7d971ed2d49a392e.BackedModel i878a80d2330e89d26896388a3f487eef27b0a0e6c010c493bf80be1452208f91.Parsable GetBackingStore()(ie8677ce2c7e1b4c22e9c3827ecd078d41185424dd9eeb92b7d971ed2d49a392e.BackingStore) GetContainerDisplayName()(*string) GetContainerType()(*string) GetContainerWebUrl()(*string) GetMediaType()(*string) GetOdataType()(*string) GetPreviewImageUrl()(*string) GetPreviewText()(*string) GetTitle()(*string) GetTypeEscaped()(*string) SetBackingStore(value ie8677ce2c7e1b4c22e9c3827ecd078d41185424dd9eeb92b7d971ed2d49a392e.BackingStore)() SetContainerDisplayName(value *string)() SetContainerType(value *string)() SetContainerWebUrl(value *string)() SetMediaType(value *string)() SetOdataType(value *string)() SetPreviewImageUrl(value *string)() SetPreviewText(value *string)() SetTitle(value *string)() SetTypeEscaped(value *string)() }