Sablon.Parser.MailMerge.ComplexField (sablon v0.4.3)

Copy Markdown View Source

A merge field spread over several runs, delimited by w:fldChar markers.

The instruction is assembled from every w:instrText element between the begin and separate markers; the run following separate holds the text Word currently displays and is the one replaced by rendered content.

Summary

Functions

Wraps the runs making up a complex field.

The run displaying the field's current value.

The run holding the separate marker, if there is one.

Types

t()

@type t() :: %Sablon.Parser.MailMerge.ComplexField{
  nodes: [Sablon.XML.Node.t()],
  raw_expression: binary(),
  ref: reference()
}

Functions

new(nodes)

@spec new([Sablon.XML.Node.t()]) :: t()

Wraps the runs making up a complex field.

pattern_node(field)

@spec pattern_node(t()) :: Sablon.XML.Node.t() | nil

The run displaying the field's current value.

separate_node(complex_field)

@spec separate_node(t()) :: Sablon.XML.Node.t() | nil

The run holding the separate marker, if there is one.