{"modulePath":"github.com/redhat-developer/Odo","version":"v1.2.6","isLatest":true,"isStandardLibrary":false,"goos":"all","goarch":"all","docs":"# package data\n\n## Constants\n\n```go\nconst (\n\tAPIVersion100 supportedApiVersion = \"1.0.0\"\n\tAPIVersion200 supportedApiVersion = \"2.0.0\"\n)\n```\nSupported devfile API versions in odo\n\n## Functions\n\n```go\nfunc GetDevfileJSONSchema(version string) (string, error)\n```\nGetDevfileJSONSchema returns the devfile JSON schema of the supported apiVersion\n\n```go\nfunc IsApiVersionSupported(version string) bool\n```\nIsApiVersionSupported returns true if the API version is supported in odo\n\n## Types\n\n```go\ntype DevfileData interface {\n\tSetSchemaVersion(version string)\n\n\tGetMetadata() common.DevfileMetadata\n\tSetMetadata(name, version string)\n\n\t// parent related methods\n\tGetParent() common.DevfileParent\n\tSetParent(parent common.DevfileParent)\n\n\t// event related methods\n\tGetEvents() common.DevfileEvents\n\tAddEvents(events common.DevfileEvents) error\n\tUpdateEvents(postStart, postStop, preStart, preStop []string)\n\n\t// component related methods\n\tGetComponents() []common.DevfileComponent\n\tAddComponents(components []common.DevfileComponent) error\n\tUpdateComponent(component common.DevfileComponent)\n\tGetAliasedComponents() []common.DevfileComponent\n\n\t// project related methods\n\tGetProjects() []common.DevfileProject\n\tAddProjects(projects []common.DevfileProject) error\n\tUpdateProject(project common.DevfileProject)\n\n\t// starter projects related commands\n\tGetStarterProjects() []common.DevfileStarterProject\n\tAddStarterProjects(projects []common.DevfileStarterProject) error\n\tUpdateStarterProject(project common.DevfileStarterProject)\n\n\t// command related methods\n\tGetCommands() map[string]common.DevfileCommand\n\tAddCommands(commands ...common.DevfileCommand) error\n\tUpdateCommand(command common.DevfileCommand)\n\n\tAddVolume(volume common.Volume, path string) error\n\tDeleteVolume(name string) error\n\tGetVolumeMountPath(name string) (string, error)\n}\n```\nDevfileData is an interface that defines functions for Devfile data operations\n\n```go\nfunc NewDevfileData(version string) (obj DevfileData, err error)\n```\nNewDevfileData returns relevant devfile struct for the provided API version\n\n","path":"github.com/redhat-developer/Odo/pkg/devfile/parser/data","name":"data","synopsis":"","isRedistributable":true}
