src/main/java/org/helm/notation2/parser/connectionsection/ConnectionsDetailsParser.java
@Override
  public void doAction(char cha) throws ConnectionSectionException,
      NotationException{
    /* a new connection is starting */
    if (cha == '|') {
      if (_parser.checkDetailsConnections(details)) {
        LOG.info("A new connection is starting:");
        ConnectionNotation current =
            _parser.notationContainer.getCurrentConnection();
        _parser.notationContainer.changeConnectionNotation(new ConnectionNotation(
            current.getSourceId(),
            current.getTargetId(), details));

        _parser.setState(new ConnectionsParser(_parser));
      } else {
        LOG.error("Details about the connection are not corret: " + details);
        throw new ConnectionSectionException("Details about the connection are not correct: " + details);
      }

    } /* connection section is finished */ else if (cha == '$') {
      if (_parser.checkDetailsConnections(details)) {
        LOG.info("Connection section is finished:");
        ConnectionNotation current =
            _parser.notationContainer.getCurrentConnection();
        _parser.notationContainer.changeConnectionNotation(new ConnectionNotation(
            current.getSourceId(),
            current.getTargetId(), details));

        LOG.info("Transition to group section");
        _parser.setState(new GroupingParser(_parser));

      } else {
        throw new ConnectionSectionException("Details about the connection are not correct: " + details);
      }
    } /* start of an annotation */ else if (cha == '\"') {
      if (_parser.checkDetailsConnections(details)) {
        LOG.info("Add annotation to connection:");
        ConnectionNotation current =
            _parser.notationContainer.getCurrentConnection();
        _parser.notationContainer.changeConnectionNotation(new ConnectionNotation(
            current.getSourceId(),
            current.getTargetId(), details));

        _parser.setState(new InlineAnnotationsParser(_parser, 2));
      } else {
        LOG.error("Details about the connection are not corret: " + details);
        throw new ConnectionSectionException("Details about the connection are not correct: " + details);
      }

    } /* add characters to connection description */ else {
      details += cha;
    }
  }
@Override
  public void doAction(char cha) throws ConnectionSectionException,
      NotationException{
    /* a new connection is starting */
    if (cha == '|') {
      if (_parser.checkDetailsConnections(details)) {
        LOG.info("A new connection is starting:");
        ConnectionNotation current =
            _parser.notationContainer.getCurrentConnection();
        _parser.notationContainer.changeConnectionNotation(new ConnectionNotation(
            current.getSourceId(),
            current.getTargetId(), details));

        _parser.setState(new ConnectionsParser(_parser));
      } else {
        LOG.error("Details about the connection are not corret: " + details);
        throw new ConnectionSectionException("Details about the connection are not correct: " + details);
      }

    } /* connection section is finished */ else if (cha == '$') {
      if (_parser.checkDetailsConnections(details)) {
        LOG.info("Connection section is finished:");
        ConnectionNotation current =
            _parser.notationContainer.getCurrentConnection();
        _parser.notationContainer.changeConnectionNotation(new ConnectionNotation(
            current.getSourceId(),
            current.getTargetId(), details));

        LOG.info("Transition to group section");
        _parser.setState(new GroupingParser(_parser));

      } else {
        throw new ConnectionSectionException("Details about the connection are not correct: " + details);
      }
    } /* start of an annotation */ else if (cha == '\"') {
      if (_parser.checkDetailsConnections(details)) {
        LOG.info("Add annotation to connection:");
        ConnectionNotation current =
            _parser.notationContainer.getCurrentConnection();
        _parser.notationContainer.changeConnectionNotation(new ConnectionNotation(
            current.getSourceId(),
            current.getTargetId(), details));

        _parser.setState(new InlineAnnotationsParser(_parser, 2));
      } else {
        LOG.error("Details about the connection are not corret: " + details);
        throw new ConnectionSectionException("Details about the connection are not correct: " + details);
      }

    } /* add characters to connection description */ else {
      details += cha;
    }
  }
@ Override public void doAction ( char cha ) throws ConnectionSectionException , NotationException { /* a new connection is starting */ if ( cha == ' ' ) { if ( _parser . checkDetailsConnections ( details ) ) { LOG . info ( "A new connection is starting:" ) ; ConnectionNotation current = _parser . notationContainer . getCurrentConnection ( ) ; _parser . notationContainer . changeConnectionNotation ( new ConnectionNotation ( current . getSourceId ( ) , current . getTargetId ( ) , details ) ) ; _parser . setState ( new ConnectionsParser ( _parser ) ) ; } else { LOG . error ( "Details about the connection are not corret: " + details ) ; throw new ConnectionSectionException ( "Details about the connection are not correct: " + details ) ; } } /* connection section is finished */ else if ( cha == ' ' ) { if ( _parser . checkDetailsConnections ( details ) ) { LOG . info ( "Connection section is finished:" ) ; ConnectionNotation current = _parser . notationContainer . getCurrentConnection ( ) ; _parser . notationContainer . changeConnectionNotation ( new ConnectionNotation ( current . getSourceId ( ) , current . getTargetId ( ) , details ) ) ; LOG . info ( "Transition to group section" ) ; _parser . setState ( new GroupingParser ( _parser ) ) ; } else { throw new ConnectionSectionException ( "Details about the connection are not correct: " + details ) ; } } /* start of an annotation */ else if ( cha == ' ' ) { if ( _parser . checkDetailsConnections ( details ) ) { LOG . info ( "Add annotation to connection:" ) ; ConnectionNotation current = _parser . notationContainer . getCurrentConnection ( ) ; _parser . notationContainer . changeConnectionNotation ( new ConnectionNotation ( current . getSourceId ( ) , current . getTargetId ( ) , details ) ) ; _parser . setState ( new InlineAnnotationsParser ( _parser , 2 ) ) ; } else { LOG . error ( "Details about the connection are not corret: " + details ) ; throw new ConnectionSectionException ( "Details about the connection are not correct: " + details ) ; } } /* add characters to connection description */ else { details += cha ; } }
{@inheritDoc}
{