From d96e2c61bb657d18fd6be5cd0c60da0065d265df Mon Sep 17 00:00:00 2001 From: Jason Streifling Date: Tue, 15 Oct 2024 20:52:35 +0200 Subject: [PATCH] Just moving code around, no change --- inlineTextContent.go | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/inlineTextContent.go b/inlineTextContent.go index fedf747..69b0d18 100644 --- a/inlineTextContent.go +++ b/inlineTextContent.go @@ -12,12 +12,6 @@ type InlineTextContent struct { Texts []string `xml:"texts,omitempty"` } -func (i *InlineTextContent) isContent() bool { return true } - -func (i *InlineTextContent) hasSRC() bool { return false } - -func (i *InlineTextContent) getType() string { return i.Type } - func newInlineTextContent(mediaType string, content any) (*InlineTextContent, error) { if mediaType != "text" && mediaType != "html" && mediaType != "" { return nil, fmt.Errorf("media type %v incompatible with inline text content", mediaType) @@ -42,6 +36,12 @@ func newInlineTextContent(mediaType string, content any) (*InlineTextContent, er return &InlineTextContent{Type: mediaType, Texts: texts}, nil } +func (i *InlineTextContent) isContent() bool { return true } + +func (i *InlineTextContent) hasSRC() bool { return false } + +func (i *InlineTextContent) getType() string { return i.Type } + func (i *InlineTextContent) Check() error { if i.Type != "" && i.Type != "text" && i.Type != "html" { return errors.New("type attribute of inline text content must be text or html if not omitted")