feat(internal): add /query API to codegen (#62)
This commit is contained in:
186
internal/api/model_import_declaration.gen.go
Normal file
186
internal/api/model_import_declaration.gen.go
Normal file
@ -0,0 +1,186 @@
|
||||
/*
|
||||
* Subset of Influx API covered by Influx CLI
|
||||
*
|
||||
* No description provided (generated by Openapi Generator https://github.com/openapitools/openapi-generator)
|
||||
*
|
||||
* API version: 2.0.0
|
||||
*/
|
||||
|
||||
// Code generated by OpenAPI Generator (https://openapi-generator.tech); DO NOT EDIT.
|
||||
|
||||
package api
|
||||
|
||||
import (
|
||||
"encoding/json"
|
||||
)
|
||||
|
||||
// ImportDeclaration Declares a package import
|
||||
type ImportDeclaration struct {
|
||||
// Type of AST node
|
||||
Type *string `json:"type,omitempty"`
|
||||
As *Identifier `json:"as,omitempty"`
|
||||
Path *StringLiteral `json:"path,omitempty"`
|
||||
}
|
||||
|
||||
// NewImportDeclaration instantiates a new ImportDeclaration object
|
||||
// This constructor will assign default values to properties that have it defined,
|
||||
// and makes sure properties required by API are set, but the set of arguments
|
||||
// will change when the set of required properties is changed
|
||||
func NewImportDeclaration() *ImportDeclaration {
|
||||
this := ImportDeclaration{}
|
||||
return &this
|
||||
}
|
||||
|
||||
// NewImportDeclarationWithDefaults instantiates a new ImportDeclaration object
|
||||
// This constructor will only assign default values to properties that have it defined,
|
||||
// but it doesn't guarantee that properties required by API are set
|
||||
func NewImportDeclarationWithDefaults() *ImportDeclaration {
|
||||
this := ImportDeclaration{}
|
||||
return &this
|
||||
}
|
||||
|
||||
// GetType returns the Type field value if set, zero value otherwise.
|
||||
func (o *ImportDeclaration) GetType() string {
|
||||
if o == nil || o.Type == nil {
|
||||
var ret string
|
||||
return ret
|
||||
}
|
||||
return *o.Type
|
||||
}
|
||||
|
||||
// GetTypeOk returns a tuple with the Type field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *ImportDeclaration) GetTypeOk() (*string, bool) {
|
||||
if o == nil || o.Type == nil {
|
||||
return nil, false
|
||||
}
|
||||
return o.Type, true
|
||||
}
|
||||
|
||||
// HasType returns a boolean if a field has been set.
|
||||
func (o *ImportDeclaration) HasType() bool {
|
||||
if o != nil && o.Type != nil {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetType gets a reference to the given string and assigns it to the Type field.
|
||||
func (o *ImportDeclaration) SetType(v string) {
|
||||
o.Type = &v
|
||||
}
|
||||
|
||||
// GetAs returns the As field value if set, zero value otherwise.
|
||||
func (o *ImportDeclaration) GetAs() Identifier {
|
||||
if o == nil || o.As == nil {
|
||||
var ret Identifier
|
||||
return ret
|
||||
}
|
||||
return *o.As
|
||||
}
|
||||
|
||||
// GetAsOk returns a tuple with the As field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *ImportDeclaration) GetAsOk() (*Identifier, bool) {
|
||||
if o == nil || o.As == nil {
|
||||
return nil, false
|
||||
}
|
||||
return o.As, true
|
||||
}
|
||||
|
||||
// HasAs returns a boolean if a field has been set.
|
||||
func (o *ImportDeclaration) HasAs() bool {
|
||||
if o != nil && o.As != nil {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetAs gets a reference to the given Identifier and assigns it to the As field.
|
||||
func (o *ImportDeclaration) SetAs(v Identifier) {
|
||||
o.As = &v
|
||||
}
|
||||
|
||||
// GetPath returns the Path field value if set, zero value otherwise.
|
||||
func (o *ImportDeclaration) GetPath() StringLiteral {
|
||||
if o == nil || o.Path == nil {
|
||||
var ret StringLiteral
|
||||
return ret
|
||||
}
|
||||
return *o.Path
|
||||
}
|
||||
|
||||
// GetPathOk returns a tuple with the Path field value if set, nil otherwise
|
||||
// and a boolean to check if the value has been set.
|
||||
func (o *ImportDeclaration) GetPathOk() (*StringLiteral, bool) {
|
||||
if o == nil || o.Path == nil {
|
||||
return nil, false
|
||||
}
|
||||
return o.Path, true
|
||||
}
|
||||
|
||||
// HasPath returns a boolean if a field has been set.
|
||||
func (o *ImportDeclaration) HasPath() bool {
|
||||
if o != nil && o.Path != nil {
|
||||
return true
|
||||
}
|
||||
|
||||
return false
|
||||
}
|
||||
|
||||
// SetPath gets a reference to the given StringLiteral and assigns it to the Path field.
|
||||
func (o *ImportDeclaration) SetPath(v StringLiteral) {
|
||||
o.Path = &v
|
||||
}
|
||||
|
||||
func (o ImportDeclaration) MarshalJSON() ([]byte, error) {
|
||||
toSerialize := map[string]interface{}{}
|
||||
if o.Type != nil {
|
||||
toSerialize["type"] = o.Type
|
||||
}
|
||||
if o.As != nil {
|
||||
toSerialize["as"] = o.As
|
||||
}
|
||||
if o.Path != nil {
|
||||
toSerialize["path"] = o.Path
|
||||
}
|
||||
return json.Marshal(toSerialize)
|
||||
}
|
||||
|
||||
type NullableImportDeclaration struct {
|
||||
value *ImportDeclaration
|
||||
isSet bool
|
||||
}
|
||||
|
||||
func (v NullableImportDeclaration) Get() *ImportDeclaration {
|
||||
return v.value
|
||||
}
|
||||
|
||||
func (v *NullableImportDeclaration) Set(val *ImportDeclaration) {
|
||||
v.value = val
|
||||
v.isSet = true
|
||||
}
|
||||
|
||||
func (v NullableImportDeclaration) IsSet() bool {
|
||||
return v.isSet
|
||||
}
|
||||
|
||||
func (v *NullableImportDeclaration) Unset() {
|
||||
v.value = nil
|
||||
v.isSet = false
|
||||
}
|
||||
|
||||
func NewNullableImportDeclaration(val *ImportDeclaration) *NullableImportDeclaration {
|
||||
return &NullableImportDeclaration{value: val, isSet: true}
|
||||
}
|
||||
|
||||
func (v NullableImportDeclaration) MarshalJSON() ([]byte, error) {
|
||||
return json.Marshal(v.value)
|
||||
}
|
||||
|
||||
func (v *NullableImportDeclaration) UnmarshalJSON(src []byte) error {
|
||||
v.isSet = true
|
||||
return json.Unmarshal(src, &v.value)
|
||||
}
|
Reference in New Issue
Block a user