xmltv/lib/Configure Writer.pm,1.7,1.8

Nick Morrott <[email protected]> Sun, 12 Jul 2015 00:59:04 +0000
Newsgroups gmane.comp.tv.xmltv.cvs
Message-ID <[email protected]>
Update of /cvsroot/xmltv/xmltv/lib/Configure
In directory sfp-cvs-1.v30.ch3.sourceforge.com:/tmp/cvs-serv21723/lib/Configure

Modified Files:
	Writer.pm 
Log Message:
Whitespace: remove trailing whitespace

Index: Writer.pm
===================================================================
RCS file: /cvsroot/xmltv/xmltv/lib/Configure/Writer.pm,v
retrieving revision 1.7
retrieving revision 1.8
diff -C2 -d -r1.7 -r1.8
*** Writer.pm	22 Jun 2015 22:36:45 -0000	1.7
--- Writer.pm	12 Jul 2015 00:59:02 -0000	1.8
***************
*** 11,15 ****
      use Exporter   ();
      our (@ISA, @EXPORT, @EXPORT_OK, %EXPORT_TAGS);
!     
      @ISA         = qw(Exporter);
      @EXPORT      = qw( );
--- 11,15 ----
      use Exporter   ();
      our (@ISA, @EXPORT, @EXPORT_OK, %EXPORT_TAGS);
! 
      @ISA         = qw(Exporter);
      @EXPORT      = qw( );
***************
*** 44,48 ****
    $writer->start( { grabber => 'tv_grab_xxx' } );
    $writer->write_string( {
!     id => 'username', 
      title => [ [ 'Username', 'en' ],
                 [ 'Användarnamn', 'sv' ] ],
--- 44,48 ----
    $writer->start( { grabber => 'tv_grab_xxx' } );
    $writer->write_string( {
!     id => 'username',
      title => [ [ 'Username', 'en' ],
                 [ 'Användarnamn', 'sv' ] ],
***************
*** 51,55 ****
      } );
    $writer->start_selectone( {
!     id => 'lineup', 
      title => [ [ 'Lineup', 'en' ],
                 [ 'Programpaket', 'sv' ] ],
--- 51,55 ----
      } );
    $writer->start_selectone( {
!     id => 'lineup',
      title => [ [ 'Lineup', 'en' ],
                 [ 'Programpaket', 'sv' ] ],
***************
*** 58,71 ****
      } );
  
!   $writer->write_option( { 
      value=>'eastcoast',
      text=> => [ [ 'East Coast', 'en' ],
!                 [ 'Östkusten', 'sv' ] ] 
    } );
  
!   $writer->write_option( { 
      value=>'westcoast',
      text=> => [ [ 'West Coast', 'en' ],
!                 [ 'Västkusten', 'sv' ] ] 
    } );
  
--- 58,71 ----
      } );
  
!   $writer->write_option( {
      value=>'eastcoast',
      text=> => [ [ 'East Coast', 'en' ],
!                 [ 'Östkusten', 'sv' ] ]
    } );
  
!   $writer->write_option( {
      value=>'westcoast',
      text=> => [ [ 'West Coast', 'en' ],
!                 [ 'Västkusten', 'sv' ] ]
    } );
  
***************
*** 91,95 ****
      my $self = $class->SUPER::new(DATA_MODE => 1, DATA_INDENT => 2, %args);
      bless($self, $class);
!     
      if (defined $encoding) {
  	$self->xmlDecl($encoding);
--- 91,95 ----
      my $self = $class->SUPER::new(DATA_MODE => 1, DATA_INDENT => 2, %args);
      bless($self, $class);
! 
      if (defined $encoding) {
  	$self->xmlDecl($encoding);
***************
*** 118,122 ****
  =item start()
  
! Write the start of the <xmltvconfiguration> element.  Parameter is 
  a hashref which gives the attributes of this element.
  
--- 118,122 ----
  =item start()
  
! Write the start of the <xmltvconfiguration> element.  Parameter is
  a hashref which gives the attributes of this element.
  
***************
*** 127,134 ****
      die 'usage: XMLTV::Writer->start(hashref of attrs)' if @_ != 1;
      my $attrs = shift;
!     
      $self->{xmltv_state} eq 'new'
  	or croak 'cannot call start() more than once on XMLTV::Writer';
!     
      $self->startTag( 'xmltvconfiguration', %{$attrs} );
      $self->{xmltv_state}='root';
--- 127,134 ----
      die 'usage: XMLTV::Writer->start(hashref of attrs)' if @_ != 1;
      my $attrs = shift;
! 
      $self->{xmltv_state} eq 'new'
  	or croak 'cannot call start() more than once on XMLTV::Writer';
! 
      $self->startTag( 'xmltvconfiguration', %{$attrs} );
      $self->{xmltv_state}='root';
***************
*** 136,145 ****
  
  =item write_string()
!     
  Write a <string> element. Parameter is a hashref with the data for the
  element:
  
    $writer->write_string( {
!     id => 'username', 
      title => [ [ 'Username', 'en' ],
                 [ 'Användarnamn', 'sv' ] ],
--- 136,145 ----
  
  =item write_string()
! 
  Write a <string> element. Parameter is a hashref with the data for the
  element:
  
    $writer->write_string( {
!     id => 'username',
      title => [ [ 'Username', 'en' ],
                 [ 'Användarnamn', 'sv' ] ],
***************
*** 149,163 ****
      } );
  
! 		
  To add a constant use 'constant' key:
  	If constant value is empty then revert to 'ask' procedure.
  
    $writer->write_string( {
!     id => 'version', 
      title => [ [ 'Version number', 'en' ] ],
      description => [ [ 'Automatically added version number - no user input', 'en' ] ],
      constant => '123',
      } );
! 		
  =back
  
--- 149,163 ----
      } );
  
! 
  To add a constant use 'constant' key:
  	If constant value is empty then revert to 'ask' procedure.
  
    $writer->write_string( {
!     id => 'version',
      title => [ [ 'Version number', 'en' ] ],
      description => [ [ 'Automatically added version number - no user input', 'en' ] ],
      constant => '123',
      } );
! 
  =back
  
***************
*** 201,225 ****
      my $id = delete $ch{id};
      die "missing 'id' in string" if not defined $id;
!     
      my %h = ( id => $id );
      my $default = delete $ch{default};
!     
      $h{default} = $default if defined $default;
! 		
!     my $constant = delete $ch{constant};  
      $h{constant} = $constant if defined $constant;
!     
      $self->startTag( $tag, %h );
!     
      my $titles = delete $ch{title};
      die "missing 'title' in string" if not defined $titles;
!     
      $self->write_lang_tag( 'title', $titles );
!     
      my $descriptions = delete $ch{description};
      die "missing 'description' in string" if not defined $descriptions;
!     
      $self->write_lang_tag( 'description', $descriptions );
!     
      $self->endTag( $tag )
      }
--- 201,225 ----
      my $id = delete $ch{id};
      die "missing 'id' in string" if not defined $id;
! 
      my %h = ( id => $id );
      my $default = delete $ch{default};
! 
      $h{default} = $default if defined $default;
! 
!     my $constant = delete $ch{constant};
      $h{constant} = $constant if defined $constant;
! 
      $self->startTag( $tag, %h );
! 
      my $titles = delete $ch{title};
      die "missing 'title' in string" if not defined $titles;
! 
      $self->write_lang_tag( 'title', $titles );
! 
      my $descriptions = delete $ch{description};
      die "missing 'description' in string" if not defined $descriptions;
! 
      $self->write_lang_tag( 'description', $descriptions );
! 
      $self->endTag( $tag )
      }
***************
*** 249,253 ****
      croak 'undef parameter hash passed' if not defined $ch;
      croak "expected a hashref, got: $ch" if ref $ch ne 'HASH';
!     
      for ($self->{xmltv_state}) {
  	if ($_ eq 'new') {
--- 249,253 ----
      croak 'undef parameter hash passed' if not defined $ch;
      croak "expected a hashref, got: $ch" if ref $ch ne 'HASH';
! 
      for ($self->{xmltv_state}) {
  	if ($_ eq 'new') {
***************
*** 272,293 ****
      my $id = delete $ch{id};
      die "missing 'id' in $tag" if not defined $id;
!     
      my %h = ( id => $id );
      my $default = delete $ch{default};
!     
      $h{default} = $default if defined $default;
!     
      $self->startTag( $tag, %h );
!     
      my $titles = delete $ch{title};
      die "missing 'title' in string" if not defined $titles;
!     
      $self->write_lang_tag( 'title', $titles );
!     
      my $descriptions = delete $ch{description};
      die "missing 'description' in string" if not defined $descriptions;
!     
      $self->write_lang_tag( 'description', $descriptions );
!     
      $self->{xmltv_state} = $tag;
  }
--- 272,293 ----
      my $id = delete $ch{id};
      die "missing 'id' in $tag" if not defined $id;
! 
      my %h = ( id => $id );
      my $default = delete $ch{default};
! 
      $h{default} = $default if defined $default;
! 
      $self->startTag( $tag, %h );
! 
      my $titles = delete $ch{title};
      die "missing 'title' in string" if not defined $titles;
! 
      $self->write_lang_tag( 'title', $titles );
! 
      my $descriptions = delete $ch{description};
      die "missing 'description' in string" if not defined $descriptions;
! 
      $self->write_lang_tag( 'description', $descriptions );
! 
      $self->{xmltv_state} = $tag;
  }
***************
*** 295,304 ****
  sub end_select {
      my( $self, $tag ) = @_;
!     
      if( $self->{xmltv_state} ne $tag )
      {
  	croak "cannot write end-tag for $tag without a matching start-tag";
      }
!     
      $self->endTag( $tag );
      $self->{xmltv_state} = 'root';
--- 295,304 ----
  sub end_select {
      my( $self, $tag ) = @_;
! 
      if( $self->{xmltv_state} ne $tag )
      {
  	croak "cannot write end-tag for $tag without a matching start-tag";
      }
! 
      $self->endTag( $tag );
      $self->{xmltv_state} = 'root';
***************
*** 308,312 ****
      my $self = shift;
      my( $data ) = @_;
!     
      for ($self->{xmltv_state}) {
  	if ($_ eq 'new') {
--- 308,312 ----
      my $self = shift;
      my( $data ) = @_;
! 
      for ($self->{xmltv_state}) {
  	if ($_ eq 'new') {
***************
*** 327,338 ****
  	else { die }
      }
!     
      my $value = delete $data->{value};
      croak "Missing value for option-tag" unless defined $value;
!     
      $self->startTag( 'option', value => $value );
      $self->write_lang_tag( 'text', $data->{text} );
      $self->endTag( 'option' );
!     
  }
  
--- 327,338 ----
  	else { die }
      }
! 
      my $value = delete $data->{value};
      croak "Missing value for option-tag" unless defined $value;
! 
      $self->startTag( 'option', value => $value );
      $self->write_lang_tag( 'text', $data->{text} );
      $self->endTag( 'option' );
! 
  }

------------------------------------------------------------------------------
Don't Limit Your Business. Reach for the Cloud.
GigeNET's Cloud Solutions provide you with the tools and support that
you need to offload your IT needs and focus on growing your business.
Configured For All Businesses. Start Your Cloud Today.
https://www.gigenetcloud.com/

_______________________________________________
xmltv-commit mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/xmltv-commit