github.com/sacloud/iaas-api-go@v1.12.0/internal/dsl/meta/types.go (about)

     1  // Copyright 2022-2023 The sacloud/iaas-api-go Authors
     2  //
     3  // Licensed under the Apache License, Version 2.0 (the "License");
     4  // you may not use this file except in compliance with the License.
     5  // You may obtain a copy of the License at
     6  //
     7  //      http://www.apache.org/licenses/LICENSE-2.0
     8  //
     9  // Unless required by applicable law or agreed to in writing, software
    10  // distributed under the License is distributed on an "AS IS" BASIS,
    11  // WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
    12  // See the License for the specific language governing permissions and
    13  // limitations under the License.
    14  
    15  package meta
    16  
    17  import (
    18  	"reflect"
    19  	"time"
    20  
    21  	"github.com/sacloud/iaas-api-go/types"
    22  )
    23  
    24  var (
    25  	// TypeID ID型
    26  	TypeID = Static(types.ID(0))
    27  	// TypeFlag フラグ型(boolean)
    28  	TypeFlag = Static(false)
    29  	// TypeStringFlag 文字列フラグ型
    30  	TypeStringFlag = Static(types.StringFalse)
    31  	// TypeStringNumber 文字列数値型
    32  	TypeStringNumber = Static(types.StringNumber(0))
    33  	// TypeString 文字列
    34  	TypeString = Static("")
    35  	// TypeStringSlice 文字列スライス
    36  	TypeStringSlice = Static([]string{})
    37  	// TypeInt int型
    38  	TypeInt = Static(int(0))
    39  	// TypeIntSlice intスライス
    40  	TypeIntSlice = Static([]int{})
    41  	// TypeInt64 int64型
    42  	TypeInt64 = Static(int64(0))
    43  	// TypeInt64Slice int64スライス
    44  	TypeInt64Slice = Static([]int64{})
    45  	// TypeFloat64 flat64型
    46  	TypeFloat64 = Static(float64(0))
    47  	// TypeTime Time型
    48  	TypeTime = Static(time.Time{})
    49  
    50  	// TypeReader io.Reader
    51  	TypeReader = &StaticType{
    52  		goType:       "io.Reader",
    53  		goPkg:        "io",
    54  		goImportPath: "io",
    55  		reflectKind:  reflect.Interface,
    56  	}
    57  	// TypeWriter io.Writer
    58  	TypeWriter = &StaticType{
    59  		goType:       "io.Writer",
    60  		goPkg:        "io",
    61  		goImportPath: "io",
    62  		reflectKind:  reflect.Interface,
    63  	}
    64  
    65  	// TypeAvailability 有効状態
    66  	TypeAvailability = Static(types.EAvailability(""))
    67  	// TypeCommitment サーバプランCPUコミットメント
    68  	TypeCommitment = Static(types.ECommitment(""))
    69  	// TypeDiskConnection ディスク接続方法
    70  	TypeDiskConnection = Static(types.EDiskConnection(""))
    71  	// TypeInstanceStatus インスタンスステータス
    72  	TypeInstanceStatus = Static(types.EServerInstanceStatus(""))
    73  	// TypeInterfaceDriver インターフェースドライバ
    74  	TypeInterfaceDriver = Static(types.EInterfaceDriver(""))
    75  	// TypePlanGeneration プラン世代
    76  	TypePlanGeneration = Static(types.EPlanGeneration(0))
    77  	// TypeProtocol プロトコル
    78  	TypeProtocol = Static(types.Protocol(""))
    79  	// TypeScope スコープ
    80  	TypeScope = Static(types.EScope(""))
    81  
    82  	// TypePacketFilterNetwork パケットフィルタルールでの送信元アドレス/範囲
    83  	TypePacketFilterNetwork = Static(types.PacketFilterNetwork(""))
    84  	// TypePacketFilterPort パケットフィルタルールでのポート
    85  	TypePacketFilterPort = Static(types.PacketFilterPort(""))
    86  	// TypeVPCFirewallNetwork VPCルータのファイアウォールルールでの送信元アドレス/範囲
    87  	TypeVPCFirewallNetwork = Static(types.VPCFirewallNetwork(""))
    88  	// TypeVPCFirewallPort VPCルータのファイアウォールルールでのポート
    89  	TypeVPCFirewallPort = Static(types.VPCFirewallPort(""))
    90  	// TypeAction パケットフィルタルールでのallow/deny動作
    91  	TypeAction = Static(types.Action(""))
    92  
    93  	// TypeBackupSpanType 自動バックアップの取得間隔種別
    94  	TypeBackupSpanType = Static(types.EBackupSpanType(""))
    95  	// TypeBackupSpanWeekdays 自動バックアップの取得曜日
    96  	TypeBackupSpanWeekdays = Static([]types.EDayOfTheWeek{})
    97  
    98  	// TypeDNSRecordType DNSレコード種別
    99  	TypeDNSRecordType = Static(types.EDNSRecordType(""))
   100  
   101  	// TypeSimpleMonitorHealthCheckProtocol シンプル監視 ヘルスチェックプロトコル
   102  	TypeSimpleMonitorHealthCheckProtocol = Static(types.ESimpleMonitorProtocol(""))
   103  )