Documentation ¶
Index ¶
Constants ¶
View Source
const (
SimpleDocType processor.DocumentType = "simple-doc"
)
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type SimpleDocProc ¶
type SimpleDocProc struct{}
SimpleDocProc is a document processor for a simple document It is of JSON blob type
It should have an issuer field, that should match up with issuer URI in TrustInformation
SourceInformation should be propagated ¶
Schema check should include: issuer (required) - string info (optional) - string nested - list of objects that match currnet schema
and no other fields
Example object is
{ "issuer": "google.com", "info": "this is a cool document" }
Example object with nested is
{ "issuer": "google.com", "info": "this is a cool document", "nested": [{ "issuer": "google.com", "info": "this is a cooler nested doc 1" },{ "issuer": "google.com", "info": "this is a cooler nested doc 2" }] }
func (*SimpleDocProc) GuessDocumentType ¶
func (_ *SimpleDocProc) GuessDocumentType(blob []byte, f processor.FormatType) processor.DocumentType
func (*SimpleDocProc) ValidateSchema ¶
func (dp *SimpleDocProc) ValidateSchema(d *processor.Document) error
Click to show internal directories.
Click to hide internal directories.