Beispiel #1
0
    /**
     * Returns path to component from property |path|.
     *
     * @param path Path to property
     * @return Path as string to component
     */
    private String componentPath(Binder.ObjectPath path) {
      this.logger.log(Level.FINER, "path = {0}", path);

      StringBuffer buff = new StringBuffer(path.start.getProperty());
      ObjectPathElement elmt = path.start.getNext();

      while (elmt != null) {
        buff.append('.').append(elmt.getProperty());

        elmt = elmt.getNext();
      } // end of while

      this.logger.log(Level.FINER, "buff = {0}", buff);

      return buff.toString();
    } // end of componentPath
Beispiel #2
0
    /** Path to size property, |element| belongs to, is completed. */
    public final void pathCompleted(ObjectPathElement element) {
      this.logger.log(Level.FINER, "element = {0}", element);

      element.removeObjectPathListener(this);

      if (this.waitedComponents == null) {
        this.logger.finer("All waited components are already known");

        return;
      } // end of if

      // ---

      Object component = element.getValue();
      // assert component != null;

      Integer h = new Integer(System.identityHashCode(component));

      this.logger.log(Level.FINER, "component = {0}, hash code = {1}", new Object[] {component, h});

      this.waitedComponents.add(h);

      addComponentSizeListeners(component);
    } // end of pathCompleted