Get an empty node sequence.

@param width the width of the batches; must be positive
@return the empty node sequence; never null
773235
public static NodeSequence emptySequence( final int width ) {
        assert width >= 0;
        return new NodeSequence() {
            @Override
            public int width() {
                return width;
            }

            @Override
            public Batch nextBatch() {
                return null;
            }

            @Override
            public long getRowCount() {
                return 0;
            }

            @Override
            public boolean isEmpty() {
                return true;
            }

            @Override
            public void close() {
            }

            @Override
            public String toString() {
                return "(empty-sequence width=" + width() + ")";
            }
        };
    }
256523
public int getWidth(ViewNode node) {
		int width = node.getDepth();
		ViewNode children[] = node.findChildren();
		for (int i = 0; i < children.length; i++) {
			int current = getWidth(children[i]);
			if (current > width)
				width = current;
		}
		return (width);
	}
249878
public String getNodeNameX(int nodeHandle)
  {

    /** @todo: implement this org.apache.xml.dtm.DTMDefaultBase abstract method */
    error(XMLMessages.createXMLMessage(XMLErrorResources.ER_METHOD_NOT_SUPPORTED, null));//"Not yet supported!");

    return null;
  }
485029
public String getSequence(Long beginPosition, Long endPosition)
	{
		byte[] sequenceByte = getSequenceByte(beginPosition, endPosition);
		if (sequenceByte != null)
			return new String(sequenceByte);
		return null;
	}
353132
public HelpTopicNode getNextSibling() {
        int i = getIndex() + 1;
        return i == 0 || i == parent.children.size() ? null : parent.children.get(i);
    }
1001494
public final double getWidth(int line) {
        if (strArray.length == 0) return 0.0;

        try {
            return textRenderer.getBounds(strArray[line]).getWidth();
        } catch (GLException e) {
            reset = true;
        }

        return 0.0;
    }
278032
private Node getSequence(IdSourceKey idSourceKey) {
		String updateSequenceQuery = getQuery( idSourceKey );
		Result result = neo4jDb.execute( updateSequenceQuery, singletonMap( SEQUENCE_NAME_QUERY_PARAM, (Object) sequenceName( idSourceKey ) ) );
		ResourceIterator<Node> column = result.columnAs( "n" );
		Node node = null;
		if ( column.hasNext() ) {
			node = column.next();
		}
		column.close();
		return node;
	}
800364
@Override
	public Long nextValue(NextValueRequest request) {
		Transaction tx = neo4jDb.beginTx();
		Lock lock = null;
		try {
			Node sequence = getSequence( request.getKey() );

			if ( sequence == null ) {
				// sequence nodes are expected to have been created up-front
				if ( request.getKey().getMetadata().getType() == IdSourceType.SEQUENCE ) {
					throw logger.sequenceNotFound( sequenceName( request.getKey() ) );
				}
				// table sequence nodes (think of them as rows in a generator table) are created upon first usage
				else {
					addTableSequence( request );
					sequence = getSequence( request.getKey() );
				}
			}

			lock = tx.acquireWriteLock( sequence );
			long nextValue = updateSequenceValue( request.getKey(), sequence, request.getIncrement() );
			tx.success();
			lock.release();
			return nextValue;
		}
		finally {
			tx.close();
		}
	}
573654
@Override
  public Row<K, N, V> peekLast() {
    return rowsList != null && rowsList.size() > 0 ? rowsList.get(rowsList.size()-1) : null;
  }
860268
public final CharSequence getEntry() {
        int index = indexOf(value);
        return index >= 0 && getEntries() != null ? getEntries()[index] : null;
    }
71068
public static <S extends Sequence<C>, C extends Compound> String getIDFormat(List<S> sequences) {
		int length = 0;
		for (S as : sequences) {
			length = Math.max(length, (as.getAccession() == null) ? 0 : as.getAccession().toString().length());
		}
		return (length == 0) ? null : "%-" + (length + 1) + "s";
	}
703123
def node_width(self):
        
        nodes = self.postorder()
        node_width = {}
        for node in nodes:
            sum_width = 0
            for child in self[node].nodes():
                sum_width += node_width[child]
            node_width[node] = (sum_width or 1)
        return node_width
667376
public int getEmptySize()
    {
        int size = 0;
        for (int i = 0; i < getBaseArraySize(); i++)
        {
            if (isEmpty(i))
            {
                ++size;
            }
        }
        return size;
    }
533676
public SequenceLabel getNextToken() {
    if (this.nextToken == null) {
      try {
        this.nextToken = this.jlexer.yylex();
      } catch (final IOException e) {
        // TODO Auto-generated catch block
        e.printStackTrace();
      }
    }
    final SequenceLabel result = this.nextToken;
    this.nextToken = null;
    if (result == null) {
      throw new NoSuchElementException();
    }
    return result;
  }
278774
public S getEmptySequence() {
        if (empty == null)
            synchronized (this) {
                if (empty == null)
                    empty = createBuilder().createAndDestroy();
            }
        return empty;
    }
943621
NodeAVL getNextNode(NodeAVL n) {

        if (n == null) {
            n = nPrimaryNode;
        } else {
            n = n.nNext;
        }

        return n;
    }
93638
public int getRowWidth() {

        int overallWidth = 0;
        for (int i = 0; i < data.length; i++) {
            overallWidth += getTable().getColumnWidth(i);
        }
        return overallWidth;
    }