Documentation
¶
Index ¶
- Variables
- func AdminContext(ctx context.Context, bypassAdminRemoval, includeBeta bool) context.Context
- type AllData
- type AssetName
- type AssetNameEx
- type AssetNameExFld
- type AssetNameExNormal
- type AssetNameExUrf
- type CMS
- func (c *CMS) GetAll(ctx context.Context, project string) (*AllData, error)
- func (c *CMS) GetCityItems(ctx context.Context, project string, featureTypes []FeatureType) ([]*CityItem, error)
- func (c *CMS) GetFeatureTypes(ctx context.Context, project string) (FeatureTypes, error)
- func (c *CMS) GetGenericItems(ctx context.Context, project string) ([]*GenericItem, error)
- func (c *CMS) GetGeospatialjpDataItems(ctx context.Context, project string) ([]*GeospatialjpDataItem, error)
- func (c *CMS) GetPlateauItems(ctx context.Context, project, feature string) ([]*PlateauFeatureItem, error)
- func (c *CMS) GetPlateauSpecs(ctx context.Context, project string) ([]plateauapi.PlateauSpecSimple, error)
- func (c *CMS) GetRelatedItems(ctx context.Context, project string, featureTypes []FeatureType) ([]*RelatedItem, error)
- type CMSInfo
- type CityItem
- func (c *CityItem) GetOpenDataURL() string
- func (i *CityItem) IsPublicOrBeta() bool
- func (c *CityItem) PlanarCrsEpsgCode() string
- func (i *CityItem) PlateauStage(ft string) stage
- func (i *CityItem) SDKStage() stage
- func (city *CityItem) ToCity() *plateauapi.City
- func (city *CityItem) ToPrefecture() *plateauapi.Prefecture
- func (i *CityItem) YearInt() int
- type Dic
- type DicEntry
- type FeatureType
- type FeatureTypes
- type GenericItem
- type GenericItemDataset
- type GeospatialjpDataItem
- type LayerNames
- type ManagementStatus
- type OriginalAndConv
- type PlateauFeatureItem
- type PlateauFeatureItemDatum
- type RelatedAssetName
- type RelatedItem
- type RelatedItemDatum
- type Repos
- type StringOrNumber
- type ToPlateauDatasetsOptions
- type UrfType
Constants ¶
This section is empty.
Variables ¶
View Source
var UrfFeatureTypeMap map[string]UrfType
UrfFeatureTypeMap is a map of URF feature type code to name.
View Source
var UrfFeatureTypes []string
UrfFeatureTypes is a list of URF feature type codes.
Functions ¶
Types ¶
type AllData ¶
type AllData struct { Name string Year int PlateauSpecs []plateauapi.PlateauSpecSimple FeatureTypes FeatureTypes City []*CityItem Related []*RelatedItem Generic []*GenericItem Plateau map[string][]*PlateauFeatureItem GeospatialjpDataItems []*GeospatialjpDataItem CMSInfo CMSInfo }
func (*AllData) FeatureTypesOf ¶
func (*AllData) FindPlateauFeatureItemByCityID ¶
func (d *AllData) FindPlateauFeatureItemByCityID(ft, cityID string) *PlateauFeatureItem
func (*AllData) Into ¶
func (all *AllData) Into() (res *plateauapi.InMemoryRepoContext, warning []string)
type AssetName ¶
type AssetName struct { CityCode string CityName string Provider string Year int Format string UpdateCount int Ex AssetNameEx }
func ParseAssetName ¶
func ParseAssetUrls ¶
type AssetNameEx ¶
type AssetNameEx struct { Normal *AssetNameExNormal Urf *AssetNameExUrf Fld *AssetNameExFld Ex string }
func ParseAssetNameEx ¶
func ParseAssetNameEx(name string) (ex AssetNameEx)
func (AssetNameEx) DatasetItemKey ¶
func (ex AssetNameEx) DatasetItemKey() string
func (AssetNameEx) DatasetKey ¶
func (ex AssetNameEx) DatasetKey() string
func (AssetNameEx) DicKey ¶
func (ex AssetNameEx) DicKey() string
func (AssetNameEx) IsValid ¶
func (ex AssetNameEx) IsValid() bool
func (AssetNameEx) String ¶
func (ex AssetNameEx) String() string
type AssetNameExFld ¶
type AssetNameExFld struct { Type string Admin string River string Format string L int Suffix string NoTexture bool }
func ParseAssetNameExFld ¶
func ParseAssetNameExFld(name string) *AssetNameExFld
func (AssetNameExFld) DatasetItemKey ¶
func (ex AssetNameExFld) DatasetItemKey() string
func (AssetNameExFld) DatasetKey ¶
func (ex AssetNameExFld) DatasetKey() string
func (AssetNameExFld) DicKey ¶
func (ex AssetNameExFld) DicKey() string
type AssetNameExNormal ¶
type AssetNameExNormal struct { Type string Format string WardCode string WardName string LOD int NoTexture bool }
func ParseAssetNameExNormal ¶
func ParseAssetNameExNormal(name string) *AssetNameExNormal
func (AssetNameExNormal) DatasetItemKey ¶
func (ex AssetNameExNormal) DatasetItemKey() string
func (AssetNameExNormal) DatasetKey ¶
func (ex AssetNameExNormal) DatasetKey() string
func (AssetNameExNormal) DicKey ¶
func (ex AssetNameExNormal) DicKey() string
type AssetNameExUrf ¶
func ParseAssetNameExUrf ¶
func ParseAssetNameExUrf(name string) *AssetNameExUrf
func (AssetNameExUrf) DatasetItemKey ¶
func (ex AssetNameExUrf) DatasetItemKey() string
func (AssetNameExUrf) DatasetKey ¶
func (ex AssetNameExUrf) DatasetKey() string
func (AssetNameExUrf) DicKey ¶
func (ex AssetNameExUrf) DicKey() string
type CMS ¶
type CMS struct {
// contains filtered or unexported fields
}
func (*CMS) GetCityItems ¶
func (*CMS) GetFeatureTypes ¶
func (*CMS) GetGenericItems ¶
func (*CMS) GetGeospatialjpDataItems ¶
func (*CMS) GetPlateauItems ¶
func (*CMS) GetPlateauSpecs ¶
func (c *CMS) GetPlateauSpecs(ctx context.Context, project string) ([]plateauapi.PlateauSpecSimple, error)
func (*CMS) GetRelatedItems ¶
func (c *CMS) GetRelatedItems(ctx context.Context, project string, featureTypes []FeatureType) ([]*RelatedItem, error)
type CityItem ¶
type CityItem struct { ID string `json:"id,omitempty" cms:"id"` Prefecture string `json:"prefecture,omitempty" cms:"prefecture,select"` CityName string `json:"city_name,omitempty" cms:"city_name,text"` CityNameEn string `json:"city_name_en,omitempty" cms:"city_name_en,text"` CityCode string `json:"city_code,omitempty" cms:"city_code,text"` Spec string `json:"spec,omitempty" cms:"spec,select"` References map[string]string `json:"references,omitempty" cms:"-"` RelatedDataset string `json:"related_dataset,omitempty" cms:"related_dataset,reference"` Year string `json:"year,omitempty" cms:"year,select"` PRCS cmsintegrationcommon.PRCS `json:"prcs,omitempty" cms:"prcs,select"` OpenDataURL string `json:"open_data_url,omitempty" cms:"open_data_url,text"` // meatadata PlateauDataStatus *cms.Tag `json:"plateau_data_status,omitempty" cms:"plateau_data_status,select,metadata"` RelatedDataStatus *cms.Tag `json:"related_data_status,omitempty" cms:"related_data_status,select,metadata"` CityPublic bool `json:"city_public,omitempty" cms:"city_public,bool,metadata"` SDKPublic bool `json:"sdk_public,omitempty" cms:"sdk_public,bool,metadata"` RelatedPublic bool `json:"related_public,omitempty" cms:"related_public,bool,metadata"` Public map[string]bool `json:"public,omitempty" cms:"-"` GeospatialjpPublish bool `json:"geospatialjp_publish,omitempty" cms:"geospatialjp_publish,bool,metadata"` }
func CityItemFrom ¶
func CityItemFrom(item *cms.Item, featureTypes []FeatureType) (i *CityItem)
func (*CityItem) GetOpenDataURL ¶
func (*CityItem) IsPublicOrBeta ¶
func (*CityItem) PlanarCrsEpsgCode ¶
func (*CityItem) PlateauStage ¶
func (*CityItem) ToCity ¶
func (city *CityItem) ToCity() *plateauapi.City
func (*CityItem) ToPrefecture ¶
func (city *CityItem) ToPrefecture() *plateauapi.Prefecture
type DicEntry ¶
type DicEntry struct { Name *StringOrNumber `json:"name,omitempty"` Description string `json:"description,omitempty"` Code *StringOrNumber `json:"code,omitempty"` // bldg only Admin string `json:"admin,omitempty"` // fld only Scale string `json:"scale,omitempty"` // fld only Suffix string `json:"suffix,omitempty"` // fld only (optional) SuffixDescription string `json:"suffix_description,omitempty"` // fld only (optional) Order *int `json:"order"` }
type FeatureType ¶
type FeatureType struct { Code string `json:"code,omitempty" cms:"code,text"` Name string `json:"name,omitempty" cms:"name,text"` Order int `json:"order,omitempty" cms:"order,integer"` GroupName string `json:"group_name,omitempty" cms:"group_name,text"` // for plateau SpecMajor int `json:"spec_major,omitempty" cms:"spec_major,integer"` Flood bool `json:"flood,omitempty" cms:"flood,bool"` MVTLayerName []string `json:"layer_name,omitempty" cms:"layer_name,text"` MVTLayerNamesForLOD map[int][]string `json:"layer_names_for_lod,omitempty" cms:"-"` MVTLayerNamePrefix string `json:"layer_name_prefix,omitempty" cms:"layer_name_prefix,text"` HideTexture bool `json:"hide_texture,omitempty" cms:"hide_texture,bool"` }
func (*FeatureType) ToGenericDatasetType ¶
func (f *FeatureType) ToGenericDatasetType() *plateauapi.GenericDatasetType
func (*FeatureType) ToPlateauDatasetType ¶
func (f *FeatureType) ToPlateauDatasetType(spec plateauapi.PlateauSpec) *plateauapi.PlateauDatasetType
func (*FeatureType) ToRelatedDatasetType ¶
func (f *FeatureType) ToRelatedDatasetType() *plateauapi.RelatedDatasetType
type FeatureTypes ¶
type FeatureTypes struct { Plateau []FeatureType Related []FeatureType Generic []FeatureType }
func (FeatureTypes) FindPlateauByCode ¶
func (ft FeatureTypes) FindPlateauByCode(code string) *FeatureType
func (FeatureTypes) LayerNames ¶
func (ft FeatureTypes) LayerNames() map[string]LayerNames
func (FeatureTypes) ToDatasetTypes ¶
func (ft FeatureTypes) ToDatasetTypes(specs []plateauapi.PlateauSpec) plateauapi.DatasetTypes
type GenericItem ¶
type GenericItem struct { ID string `json:"id,omitempty" cms:"id"` City string `json:"city,omitempty" cms:"city,reference"` Name string `json:"name,omitempty" cms:"name,text"` Desc string `json:"desc,omitempty" cms:"desc,textarea"` Type string `json:"type,omitempty" cms:"type,text"` TypeEn string `json:"type_en,omitempty" cms:"type_en,text"` Items []GenericItemDataset `json:"items,omitempty" cms:"items,group"` OpenDataURL string `json:"open_data_url,omitempty" cms:"open_data_url,url"` Category string `json:"category,omitempty" cms:"category,select"` // metadata Status *cms.Tag `json:"status,omitempty" cms:"status,select,metadata"` Public bool `json:"public,omitempty" cms:"public,bool,metadata"` UseAR bool `json:"use-ar,omitempty" cms:"use-ar,bool,metadata"` }
func GenericItemFrom ¶
func GenericItemFrom(item *cms.Item) (i *GenericItem)
func (*GenericItem) Stage ¶
func (c *GenericItem) Stage() stage
type GenericItemDataset ¶
type GenericItemDataset struct { ID string `json:"id,omitempty" cms:"id"` Name string `json:"name,omitempty" cms:"item_name,text"` Data string `json:"data,omitempty" cms:"data,-"` Desc string `json:"desc,omitempty" cms:"desc,textarea"` DataURL string `json:"url,omitempty" cms:"url,url"` DataFormat string `json:"format,omitempty" cms:"format,select"` LayerName string `json:"layer,omitempty" cms:"layer,text"` }
type GeospatialjpDataItem ¶
type GeospatialjpDataItem struct { ID string `json:"id,omitempty" cms:"id"` City string `json:"city,omitempty" cms:"city,reference"` CityGML string `json:"citygml,omitempty" cms:"citygml,asset"` MaxLOD string `json:"maxlod,omitempty" cms:"maxlod,asset"` }
func GeospatialjpDataItemFrom ¶
func GeospatialjpDataItemFrom(item *cms.Item) *GeospatialjpDataItem
type LayerNames ¶
func (LayerNames) LayerName ¶
func (l LayerNames) LayerName(def []string, lod int, format plateauapi.DatasetFormat) []string
type ManagementStatus ¶
type ManagementStatus string
const (
ManagementStatusReady ManagementStatus = "確認可能"
)
type OriginalAndConv ¶
func OriginalAndConvsFrom ¶
func OriginalAndConvsFrom(original, converted []string) []OriginalAndConv
type PlateauFeatureItem ¶
type PlateauFeatureItem struct { ID string `json:"id,omitempty" cms:"id"` City string `json:"city,omitempty" cms:"city,reference"` CityGML string `json:"citygml,omitempty" cms:"citygml,-"` Data []string `json:"data,omitempty" cms:"data,-"` Desc string `json:"desc,omitempty" cms:"desc,textarea"` Items []PlateauFeatureItemDatum `json:"items,omitempty" cms:"items,group"` Dic string `json:"dic,omitempty" cms:"dic,textarea"` MaxLOD string `json:"maxlod,omitempty" cms:"maxlod,-"` // metadata Sample bool `json:"sample,omitempty" cms:"sample,bool,metadata"` }
func PlateauFeatureItemFrom ¶
func PlateauFeatureItemFrom(item *cms.Item) (i *PlateauFeatureItem)
func (PlateauFeatureItem) ReadDic ¶
func (c PlateauFeatureItem) ReadDic() (d Dic, _ error)
type PlateauFeatureItemDatum ¶
type PlateauFeatureItemDatum struct { ID string `json:"id,omitempty" cms:"id"` Data []string `json:"data,omitempty" cms:"data,-"` Name string `json:"name,omitempty" cms:"name,text"` Desc string `json:"desc,omitempty" cms:"desc,textarea"` Key string `json:"key,omitempty" cms:"key,text"` // Simple indicates that this item should not use subcode and subname Simple bool `json:"simple,omitempty" cms:"-"` }
type RelatedAssetName ¶
type RelatedAssetName struct { Code string Name string Year int Provider string WardCode string WardName string Type string Format string }
func ParseRelatedAssetName ¶
func ParseRelatedAssetName(name string) *RelatedAssetName
type RelatedItem ¶
type RelatedItem struct { ID string `json:"id,omitempty" cms:"id"` City string `json:"city,omitempty" cms:"city,reference"` Items map[string]RelatedItemDatum `json:"items,omitempty" cms:"-"` Merged string `json:"merged,omitempty" cms:"merged,asset"` Status *cms.Tag `json:"status,omitempty" cms:"status,select,metadata"` }
func RelatedItemFrom ¶
func RelatedItemFrom(item *cms.Item, featureTypes []FeatureType) (i *RelatedItem)
type RelatedItemDatum ¶
type Repos ¶
type Repos struct { *plateauapi.Repos // contains filtered or unexported fields }
type StringOrNumber ¶
type StringOrNumber struct {
Value string
}
func (*StringOrNumber) String ¶
func (s *StringOrNumber) String() string
func (*StringOrNumber) UnmarshalJSON ¶
func (s *StringOrNumber) UnmarshalJSON(b []byte) error
type ToPlateauDatasetsOptions ¶
type ToPlateauDatasetsOptions struct { CMSURL string Area *areaContext Spec *plateauapi.PlateauSpecMinor DatasetType *plateauapi.PlateauDatasetType LayerNames LayerNames FeatureType *FeatureType Year int }
Source Files
¶
Click to show internal directories.
Click to hide internal directories.