rpc

package
v0.1.2 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: May 24, 2022 License: MIT Imports: 7 Imported by: 1

Documentation

Overview

Code generated by doc-generator. DO NOT EDIT.

Index

Constants

This section is empty.

Variables

View Source
var File_rpc_document_proto protoreflect.FileDescriptor

Functions

This section is empty.

Types

type Block

type Block struct {

	// ID is the block ID
	Id string `protobuf:"bytes,1,opt,name=id,proto3" json:"id,omitempty"`
	// UUID is used to reference another Document in a block.
	Uuid string `protobuf:"bytes,2,opt,name=uuid,proto3" json:"uuid,omitempty"`
	// URI is used to reference another entity in a document.
	Uri string `protobuf:"bytes,3,opt,name=uri,proto3" json:"uri,omitempty"`
	// URL is a browseable URL for the the block.
	Url string `protobuf:"bytes,4,opt,name=url,proto3" json:"url,omitempty"`
	// Type is the type of the block
	Type string `protobuf:"bytes,5,opt,name=type,proto3" json:"type,omitempty"`
	// Title is the title/headline of the block, typically used in the
	// presentation of the block.
	Title string `protobuf:"bytes,6,opt,name=title,proto3" json:"title,omitempty"`
	// Data contains block data
	Data map[string]string `` /* 149-byte string literal not displayed */
	// Relationship describes the relationship to the document/parent
	// entity
	Rel string `protobuf:"bytes,8,opt,name=rel,proto3" json:"rel,omitempty"`
	// Name is a name for the block. An alternative to "rel" when
	// relationship is a term that doesn't fit.
	Name string `protobuf:"bytes,9,opt,name=name,proto3" json:"name,omitempty"`
	// Value is a value for the block. Useful when we want to store a
	// primitive value.
	Value string `protobuf:"bytes,10,opt,name=value,proto3" json:"value,omitempty"`
	// ContentType is used to describe the content type of the
	// block/linked entity if it differs from the type of the block.
	ContentType string `protobuf:"bytes,11,opt,name=contentType,proto3" json:"contentType,omitempty"`
	// Links are used to link to other resources and documents.
	Links []*Block `protobuf:"bytes,13,rep,name=links,proto3" json:"links,omitempty"`
	// Content is used to embed content blocks.
	Content []*Block `protobuf:"bytes,14,rep,name=content,proto3" json:"content,omitempty"`
	// Meta is used to embed metadata
	Meta []*Block `protobuf:"bytes,15,rep,name=meta,proto3" json:"meta,omitempty"`
	// Role is used for
	Role string `protobuf:"bytes,16,opt,name=role,proto3" json:"role,omitempty"`
	// contains filtered or unexported fields
}

Block is the building block for data embedded in documents. It is used for both content, links and metadata. Blocks have can be nested, but that's nothing to strive for, keep it simple.

func (*Block) Descriptor deprecated

func (*Block) Descriptor() ([]byte, []int)

Deprecated: Use Block.ProtoReflect.Descriptor instead.

func (*Block) FromDocBlock

func (d *Block) FromDocBlock(doc *doc.Block) error

func (*Block) GetContent

func (x *Block) GetContent() []*Block

func (*Block) GetContentType

func (x *Block) GetContentType() string

func (*Block) GetData

func (x *Block) GetData() map[string]string

func (*Block) GetId

func (x *Block) GetId() string
func (x *Block) GetLinks() []*Block

func (*Block) GetMeta

func (x *Block) GetMeta() []*Block

func (*Block) GetName

func (x *Block) GetName() string

func (*Block) GetRel

func (x *Block) GetRel() string

func (*Block) GetRole

func (x *Block) GetRole() string

func (*Block) GetTitle

func (x *Block) GetTitle() string

func (*Block) GetType

func (x *Block) GetType() string

func (*Block) GetUri

func (x *Block) GetUri() string

func (*Block) GetUrl

func (x *Block) GetUrl() string

func (*Block) GetUuid

func (x *Block) GetUuid() string

func (*Block) GetValue

func (x *Block) GetValue() string

func (*Block) ProtoMessage

func (*Block) ProtoMessage()

func (*Block) ProtoReflect

func (x *Block) ProtoReflect() protoreflect.Message

func (*Block) Reset

func (x *Block) Reset()

func (*Block) String

func (x *Block) String() string

func (*Block) ToDocBlock

func (d *Block) ToDocBlock(doc *doc.Block) error

type Document

type Document struct {

	// UUID is a unique ID for the document, this can be a random v4
	// UUID, or a URI-derived v5 UUID.
	Uuid string `protobuf:"bytes,1,opt,name=uuid,proto3" json:"uuid,omitempty"`
	// Type is the content type of the document.
	Type string `protobuf:"bytes,3,opt,name=type,proto3" json:"type,omitempty"`
	// URI identifies the document (in a more human-readable way than
	// the UUID)
	Uri string `protobuf:"bytes,4,opt,name=uri,proto3" json:"uri,omitempty"`
	// URL is the browseable location of the document (if any)
	Url string `protobuf:"bytes,5,opt,name=url,proto3" json:"url,omitempty"`
	// Title is the title of the document, often used as the headline
	// when the document is displayed.
	Title string `protobuf:"bytes,6,opt,name=title,proto3" json:"title,omitempty"`
	// Path is the path on which the document can be exposed when
	// consumed through a website.
	Path string `protobuf:"bytes,8,opt,name=path,proto3" json:"path,omitempty"`
	// Products is a list of products that the document should be used
	// in.
	//
	// Deprecated: Do not use.
	Products []string `protobuf:"bytes,9,rep,name=products,proto3" json:"products,omitempty"`
	// Created is the initial creation time of the document.
	Created *timestamppb.Timestamp `protobuf:"bytes,10,opt,name=created,proto3" json:"created,omitempty"`
	// Modified is the modified time as is should be presented to end
	// users, the actual modified timestamp is recorded in the document
	// commit. There is probably no reason not to update this timestamp
	// when doing manual edits.  Automated tools and systems should
	// probably leave it alone tho.
	Modified *timestamppb.Timestamp `protobuf:"bytes,11,opt,name=modified,proto3" json:"modified,omitempty"`
	// Published is the published timestamp as it should be presented to
	// end users. The actual published timestamp is recorded in the
	// document commits in the "usable" branch. This shouldn't be
	// touched after the initial publishing of the document.
	Published *timestamppb.Timestamp `protobuf:"bytes,12,opt,name=published,proto3" json:"published,omitempty"`
	// Content is the content of the documen, this is essentially what
	// gets rendered on the page when you view a document.
	Content []*Block `protobuf:"bytes,13,rep,name=content,proto3" json:"content,omitempty"`
	// Meta is the metadata for a document, this could be stuff like
	// open graph tags and content profile information.
	Meta []*Block `protobuf:"bytes,14,rep,name=meta,proto3" json:"meta,omitempty"`
	// Links are links to other resources and entities. This could be
	// links to categories and subject for the document, or authors.
	Links []*Block `protobuf:"bytes,15,rep,name=links,proto3" json:"links,omitempty"`
	// Properties are header-like properties for a document. This is
	// mainly used as a bucket for document-level stuff that needs to be
	// preserved when converting to and from other document formats.
	Properties []*Property `protobuf:"bytes,16,rep,name=properties,proto3" json:"properties,omitempty"`
	// Source is the name of the source of the document, usually the
	// name of the application that generated it (or allowed a user to
	// generate it).
	Source string `protobuf:"bytes,17,opt,name=source,proto3" json:"source,omitempty"`
	// Language is the language used in the document as an IETF language
	// tag. F.ex. "en", "en-UK", "es", or "sv-SE".
	Language string `protobuf:"bytes,18,opt,name=language,proto3" json:"language,omitempty"`
	// A free form field detailing the status for the document, for example:
	// "draft" or "withheld".
	Status      string                 `protobuf:"bytes,19,opt,name=status,proto3" json:"status,omitempty"`
	Unpublished *timestamppb.Timestamp `protobuf:"bytes,20,opt,name=unpublished,proto3" json:"unpublished,omitempty"`
	Provider    string                 `protobuf:"bytes,21,opt,name=provider,proto3" json:"provider,omitempty"` // string infoSource = 22;
	// contains filtered or unexported fields
}

Document is the content, doh!

func (*Document) Descriptor deprecated

func (*Document) Descriptor() ([]byte, []int)

Deprecated: Use Document.ProtoReflect.Descriptor instead.

func (*Document) FromDocDocument

func (d *Document) FromDocDocument(doc *doc.Document) error

func (*Document) GetContent

func (x *Document) GetContent() []*Block

func (*Document) GetCreated

func (x *Document) GetCreated() *timestamppb.Timestamp

func (*Document) GetLanguage

func (x *Document) GetLanguage() string
func (x *Document) GetLinks() []*Block

func (*Document) GetMeta

func (x *Document) GetMeta() []*Block

func (*Document) GetModified

func (x *Document) GetModified() *timestamppb.Timestamp

func (*Document) GetPath

func (x *Document) GetPath() string

func (*Document) GetProducts deprecated

func (x *Document) GetProducts() []string

Deprecated: Do not use.

func (*Document) GetProperties

func (x *Document) GetProperties() []*Property

func (*Document) GetProvider

func (x *Document) GetProvider() string

func (*Document) GetPublished

func (x *Document) GetPublished() *timestamppb.Timestamp

func (*Document) GetSource

func (x *Document) GetSource() string

func (*Document) GetStatus

func (x *Document) GetStatus() string

func (*Document) GetTitle

func (x *Document) GetTitle() string

func (*Document) GetType

func (x *Document) GetType() string

func (*Document) GetUnpublished

func (x *Document) GetUnpublished() *timestamppb.Timestamp

func (*Document) GetUri

func (x *Document) GetUri() string

func (*Document) GetUrl

func (x *Document) GetUrl() string

func (*Document) GetUuid

func (x *Document) GetUuid() string

func (*Document) ProtoMessage

func (*Document) ProtoMessage()

func (*Document) ProtoReflect

func (x *Document) ProtoReflect() protoreflect.Message

func (*Document) Reset

func (x *Document) Reset()

func (*Document) String

func (x *Document) String() string

func (*Document) ToDocDocument

func (d *Document) ToDocDocument(doc *doc.Document) error

type Property

type Property struct {
	Name       string            `protobuf:"bytes,1,opt,name=name,proto3" json:"name,omitempty"`
	Value      string            `protobuf:"bytes,2,opt,name=value,proto3" json:"value,omitempty"`
	Parameters map[string]string `` /* 161-byte string literal not displayed */
	// contains filtered or unexported fields
}

Property is a key-value pair

func (*Property) Descriptor deprecated

func (*Property) Descriptor() ([]byte, []int)

Deprecated: Use Property.ProtoReflect.Descriptor instead.

func (*Property) FromDocProperty

func (d *Property) FromDocProperty(doc *doc.Property) error

func (*Property) GetName

func (x *Property) GetName() string

func (*Property) GetParameters

func (x *Property) GetParameters() map[string]string

func (*Property) GetValue

func (x *Property) GetValue() string

func (*Property) ProtoMessage

func (*Property) ProtoMessage()

func (*Property) ProtoReflect

func (x *Property) ProtoReflect() protoreflect.Message

func (*Property) Reset

func (x *Property) Reset()

func (*Property) String

func (x *Property) String() string

func (*Property) ToDocProperty

func (d *Property) ToDocProperty(doc *doc.Property) error

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL