{"modulePath":"github.com/pencode-labs/pencode","version":"v0.1.0-rc.15","isLatest":true,"isStandardLibrary":false,"goos":"all","goarch":"all","docs":"# package workspace\n\nPackage workspace owns filesystem roots and versioned documents without GUI dependencies. A Store belongs to one protocol connection and one goroutine.\n\n## Constants\n\n```go\nconst SaveTemporaryPrefix = \".pencode-save-\"\n```\nSaveTemporaryPrefix identifies files staged for an atomic save.\n\n## Functions\n\n```go\nfunc ErrorCode(err error) protocol.Code\n```\n\n## Types\n\n```go\ntype Store struct {\n\t// contains filtered or unexported fields\n}\n```\n\n```go\nfunc (s *Store) Change(id, version, offset uint64, start, end uint32, text string) (uint64, error)\n```\n\n```go\nfunc (s *Store) Close()\n```\n\n```go\nfunc (s *Store) CloseDocument(id uint64)\n```\n\n```go\nfunc (s *Store) CloseProject(id uint64) error\n```\n\n```go\nfunc (s *Store) Create(id uint64, name string, directory bool) error\n```\n\n```go\nfunc (s *Store) Import(targetID uint64, filename, directory string, overwrite bool) (string, error)\n```\n\n```go\nfunc (s *Store) Move(id, projectID uint64, name string) error\n```\n\n```go\nfunc (s *Store) Open(directory string) (protocol.Workspace, error)\n```\n\n```go\nfunc (s *Store) OpenDocument(projectID uint64, name string, mode protocol.DocumentMode) (protocol.Document, error)\n```\n\n```go\nfunc (s *Store) ReadDirectory(id uint64, name string) ([]protocol.Entry, error)\n```\n\n```go\nfunc (s *Store) ReadDocument(id, version, offset uint64) (protocol.Document, error)\n```\n\n```go\nfunc (s *Store) Remove(id uint64, name string) error\n```\n\n```go\nfunc (s *Store) Rename(id uint64, from, to string) error\n```\n\n```go\nfunc (s *Store) Save(id, version uint64) error\n```\n\n```go\nfunc (s *Store) Transfer(sourceID, targetID uint64, from, directory string, cut, duplicate bool) (string, error)\n```\n\n","path":"github.com/pencode-labs/pencode/server/workspace","name":"workspace","synopsis":"Package workspace owns filesystem roots and versioned documents without GUI dependencies.","isRedistributable":true}
