Class: AWSCDK::B2BI::CfnPartnership::WrapOptionsProperty

Inherits:
Jsii::Struct
  • Object
show all
Defined in:
b2_bi/cfn_partnership.rb

Overview

Contains options for wrapping (line folding) in X12 EDI files.

Wrapping controls how long lines are handled in the EDI output.

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(line_length: nil, line_terminator: nil, wrap_by: nil) ⇒ WrapOptionsProperty

Returns a new instance of WrapOptionsProperty.

Parameters:

  • line_length (Numeric, nil) (defaults to: nil)

    Specifies the maximum length of a line before wrapping occurs.

  • line_terminator (String, nil) (defaults to: nil)

    Specifies the character sequence used to terminate lines when wrapping. Valid values:.

  • wrap_by (String, nil) (defaults to: nil)

    Specifies the method used for wrapping lines in the EDI output. Valid values:.



745
746
747
748
749
750
751
752
# File 'b2_bi/cfn_partnership.rb', line 745

def initialize(line_length: nil, line_terminator: nil, wrap_by: nil)
  @line_length = line_length
  Jsii::Type.check_type(@line_length, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJudW1iZXIifQ==")), "lineLength") unless @line_length.nil?
  @line_terminator = line_terminator
  Jsii::Type.check_type(@line_terminator, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "lineTerminator") unless @line_terminator.nil?
  @wrap_by = wrap_by
  Jsii::Type.check_type(@wrap_by, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "wrapBy") unless @wrap_by.nil?
end

Instance Attribute Details

#line_lengthNumeric? (readonly)

Specifies the maximum length of a line before wrapping occurs.

This value is used when wrap_by is set to LINE_LENGTH .



760
761
762
# File 'b2_bi/cfn_partnership.rb', line 760

def line_length
  @line_length
end

#line_terminatorString? (readonly)

Specifies the character sequence used to terminate lines when wrapping. Valid values:.

  • CRLF : carriage return and line feed
  • LF : line feed)
  • CR : carriage return


769
770
771
# File 'b2_bi/cfn_partnership.rb', line 769

def line_terminator
  @line_terminator
end

#wrap_byString? (readonly)

Specifies the method used for wrapping lines in the EDI output. Valid values:.

  • SEGMENT : Wraps by segment.
  • ONE_LINE : Indicates that the entire content is on a single line.

When you specify ONE_LINE , do not provide either the line length nor the line terminator value.

  • LINE_LENGTH : Wraps by character count, as specified by line_length value.


781
782
783
# File 'b2_bi/cfn_partnership.rb', line 781

def wrap_by
  @wrap_by
end

Class Method Details

.jsii_propertiesObject



783
784
785
786
787
788
789
# File 'b2_bi/cfn_partnership.rb', line 783

def self.jsii_properties
  {
    :line_length => "lineLength",
    :line_terminator => "lineTerminator",
    :wrap_by => "wrapBy",
  }
end

Instance Method Details

#to_jsiiObject



791
792
793
794
795
796
797
798
799
# File 'b2_bi/cfn_partnership.rb', line 791

def to_jsii
  result = {}
  result.merge!({
    "lineLength" => @line_length,
    "lineTerminator" => @line_terminator,
    "wrapBy" => @wrap_by,
  })
  result.compact
end