Examples of Recorder


Examples of jrdesktop.viewer.Recorder

          System.out.println("Viewer.start() : " + e.getMessage());
        }
       
      Objects = new ArrayList<Object>();
     
      recorder = new Recorder(this);
     
      recorder.Start();
     
      /*
      connect();
View Full Code Here

Examples of jrdesktop.viewer.Recorder

    }
   
    public void _Start() {
        connect();
        if (connected) {
            recorder = new Recorder(this, client.clientConfig);
            rt = new robot(this);     
            getOptions();                  
            rt.running = true;            
            rt.Notify();     
        }       
View Full Code Here

Examples of net.sf.laja.parser.engine2.Recorder

  }
 
  @Override
  public boolean parse(int level, Source source, boolean parentNot, boolean caseSensitive, boolean receive) {
    level++;
    Recorder recorder = source.getRecorder();
    int bookmark = source.getBookmark();
    int recIndex = recorder.getIndex();

    for (Iterator i = list.iterator(); i.hasNext();) {
      source.setBookmark(bookmark);

      ElementOutputList.ElementOutput elementOutput = (ElementOutputList.ElementOutput)i.next();
      Element element = elementOutput.getElement();
      Output output = elementOutput.getOutput();
     
      boolean elementNot = elementOutput.isNot();

      if (this.caseSensitive != null) {
        caseSensitive = this.caseSensitive.booleanValue();
      }
      if (elementOutput.isCaseSensitive() != null) {
        caseSensitive = elementOutput.isCaseSensitive().booleanValue();
      }

      boolean match = false;
      if (output.receive()) {
        if (receive) {
          match = recorder.playMatch(element, source.getBookmark());
          source.setBookmark(recorder.playBookmark());
        } else {
          output.init(source);
          int mindex = recorder.reserveMatchIndex(level, element, source.getBookmark(), parentNot, elementNot);
          int bindex = recorder.reserveBookmarkIndex();
          match = element.parse(level, source, not|parentNot|elementNot, caseSensitive, false);
          match = match != elementNot;
          recorder.set(level, source, element, bookmark, source.getBookmark(), source.getBestIndex(), mindex, bindex, match, parentNot, elementNot);
          output.set(source, bookmark);
        }
      } else {
        if (receive) {
          match = recorder.playMatch(element, source.getBookmark());
        } else {
          int index = recorder.reserveMatchIndex(level, element, source.getBookmark(), parentNot, elementNot);
          match = element.parse(level, source, not|parentNot|elementNot, caseSensitive, false);
          match = (match != elementNot);
          recorder.set(level, source, element, bookmark, source.getBookmark(), source.getBestIndex(), index, match, parentNot, elementNot);
        }
      }

      if (match) {
        if (receive && !elementNot && !not) {
          source.setBookmark(bookmark);
          output.init(source);
          element.parse(level, source, not|parentNot|elementNot, caseSensitive, receive);
          output.set(source, bookmark);
        }
                output = list.getOutput();
                if (output != null && receive) {
                    output.init(source);
                    output.set(source, bookmark);
                }
               
                return !not;
      }
    }
    if (not) {
      source.setBookmark(bookmark);
      source.skipCharacter();

      Output output = list.getOutput();
      if (output != null && receive) {
        output.init(source);
        output.set(source, bookmark);
      }
    } else {
      recorder.setIndex(recIndex);
    }

    return not;
  }
View Full Code Here

Examples of net.sf.laja.parser.engine2.Recorder

    boolean firstMatch;

    int bookmark;
    int firstBookmark;

    Recorder recorder = source.getRecorder();
    firstBookmark = bookmark = source.getBookmark();
   
    if (maxRepeats > 0) {
      if (receive) {
        match = firstMatch = recorder.playMatch(elementList, source.getBookmark());
      } else {
        int index = recorder.reserveMatchIndex(level, elementList, source.getBookmark(), parentNot, false);
        match = elementList.parse(level, source, not|parentNot, caseSensitive, false);
        match = firstMatch = (match && source.getBookmark() != bookmark);
        recorder.set(level, source, elementList, bookmark, source.getBookmark(), source.getBestIndex(), index, match, parentNot, false);
      }
    } else {
      match = firstMatch = true;
    }
   
    int repeats = 0;
   
    if (!not) {
      while (match) {
        if (receive) {
          source.setBookmark(bookmark);
          elementList.parse(level, source, not|parentNot, caseSensitive, true);
        }
        if (++repeats >= maxRepeats) {
          break;
        }
        if (source.reachedEnd()) {
          bookmark = source.getBookmark();
          break;
        }
        bookmark = source.getBookmark();

        if (receive) {
          match = recorder.playMatch(elementList, source.getBookmark());
        } else {
          int index = recorder.reserveMatchIndex(level, elementList, source.getBookmark(), parentNot, false);
          int sourceIndex = source.getBestIndex();
          match = elementList.parse(level, source, not|parentNot, caseSensitive, false);
          match = (match && source.getBookmark() != bookmark);
          recorder.set(level, source, elementList, bookmark, source.getBookmark(), sourceIndex, index, match, parentNot, false);
        }
      }
    }

    if (!match) {
View Full Code Here

Examples of net.sf.laja.parser.engine2.Recorder

    return list.iterator().hasNext();
  }

  public boolean parse(int level, Source source, boolean parentNot, boolean caseSensitive, boolean receive) {
    level++;
    Recorder recorder = source.getRecorder();
    int bestMatchIdx = source.getBestIndex();
    int startBookmark = source.getBookmark();
    int startIndex = recorder.getIndex();
   
    for (Iterator i = list.iterator(); i.hasNext();) {
      ElementOutput elementOutput = (ElementOutput)i.next();
      Element element = elementOutput.getElement();
      Output output = elementOutput.getOutput();
      boolean elementNot = elementOutput.isNot();

      if (this.caseSensitive != null) {
        caseSensitive = this.caseSensitive.booleanValue();
      }
      if (elementOutput.isCaseSensitive() != null) {
        caseSensitive = elementOutput.isCaseSensitive().booleanValue();
      }

      int bookmark = source.getBookmark();

      boolean match = false;
      if (output.receive()) {
        if (receive) {
          match = recorder.playMatch(element, source.getBookmark());
          source.setBookmark(recorder.playBookmark());
        } else {
          output.init(source);
          int mindex = recorder.reserveMatchIndex(level, element, source.getBookmark(), parentNot, elementNot);
          int bindex = recorder.reserveBookmarkIndex();
          match = element.parse(level, source, not|parentNot|elementNot, caseSensitive, false);
          match = match != elementNot;
          recorder.set(level, source, element, bookmark, source.getBookmark(), source.getBestIndex(), mindex, bindex, match, parentNot, elementNot);
          output.set(source, bookmark);
        }
      } else {
        if (receive) {
          match = recorder.playMatch(element, source.getBookmark());
        } else {
          int mindex = recorder.reserveMatchIndex(level, element, source.getBookmark(), parentNot, elementNot);
          match = element.parse(level, source, not|parentNot|elementNot, caseSensitive, false);
          match = match != elementNot;
          recorder.set(level, source, element, bookmark, source.getBookmark(), source.getBestIndex(), mindex, match, parentNot, elementNot);
        }
      }
     
      if (match == not) {
        if (!receive) {
          recorder.setIndex(startIndex);
        }
        return false;
      }
     
      if (not) {
View Full Code Here

Examples of net.sf.laja.parser.engine2.Recorder

  public void add(int id, Element element, int flags, Output output) {
    elementList.add(id, element, flags, output);
  }

  public boolean parse(int level, Source source, boolean parentNot, boolean caseSensitive, boolean receive) {
    Recorder recorder = source.getRecorder();
    int bookmark = source.getBookmark();

    boolean match;

    if (receive) {
      match = recorder.playMatch(elementList, source.getBookmark());
    } else {
      int index = recorder.reserveMatchIndex(level, elementList, source.getBookmark(), parentNot, false);
      match = elementList.parse(level, source, parentNot, caseSensitive, false);
      recorder.set(level, source, elementList, bookmark, source.getBookmark(), source.getBestIndex(), index, match, parentNot, false);
    }
   
    if (!match) {
      source.setBookmark(bookmark);
    }
View Full Code Here

Examples of net.sf.sahi.record.Recorder

    this.sendHTMLResponseAfterFileDownload = b;
  }
 
  public Recorder getRecorder() {
    if (this.recorder == null) {
      this.recorder = new Recorder();
    }
    return recorder;
  }
View Full Code Here

Examples of org.apache.wicket.extensions.markup.html.form.palette.component.Recorder

                private static final long serialVersionUID = -3415146226879212841L;

                @Override
                protected Recorder newRecorderComponent() {
                    Recorder recorder = super.newRecorderComponent();
                    recorder.add(new AjaxFormComponentUpdatingBehavior("change") {

                        private static final long serialVersionUID = 5538299138211283825L;

                        @Override
                        protected void onUpdate(final AjaxRequestTarget target) {
View Full Code Here

Examples of org.apache.wicket.extensions.markup.html.form.palette.component.Recorder

   * @return tracker component
   */
  protected Recorder newRecorderComponent()
  {
    // create component that will keep track of selections
    return new Recorder("recorder", this)
    {
      private static final long serialVersionUID = 1L;

      public void updateModel()
      {
View Full Code Here

Examples of org.apache.wicket.extensions.markup.html.form.palette.component.Recorder

            // trick to force the palette to have at least one selected elements
            // tried with a nicer validator but it's not used at all, the required thing
            // instead is working (don't know why...)
            protected Recorder newRecorderComponent() {
                Recorder rec = super.newRecorderComponent();
                rec.setRequired(true);
                return rec;
            }
        };
    }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.