/** * Returns an empty {@link TupleTagList}. * * <p>Longer {@link TupleTagList TupleTagLists} can be created by calling {@link #and} on the * result. */ public static TupleTagList empty() { return new TupleTagList(); }
/** * Returns a new {@link TupleTagList} that has all the {@link TupleTag TupleTags} of this {@link * TupleTagList} plus the given {@link TupleTag TupleTags} appended to the end, in order. */ public TupleTagList and(List<TupleTag<?>> tags) { return new TupleTagList( new ImmutableList.Builder<TupleTag<?>>().addAll(tupleTags).addAll(tags).build()); }
/** * Returns a new {@link TupleTagList} that has all the {@link TupleTag TupleTags} of this {@link * TupleTagList} plus the given {@link TupleTag} appended to the end. */ public TupleTagList and(TupleTag<?> tag) { return new TupleTagList( new ImmutableList.Builder<TupleTag<?>>().addAll(tupleTags).add(tag).build()); }