Class AllButLast
- All Implemented Interfaces:
- Cloneable,- Iterable<Resource>,- ResourceCollection
ResourceCollection that contains all resources of another
 collection except for the last 
count elements, a la
 the UNIX head command with parameter -n -count.- Since:
- Ant 1.9.5
- 
Field SummaryFields inherited from class org.apache.tools.ant.ProjectComponentdescription, location, project
- 
Constructor SummaryConstructors
- 
Method SummaryModifier and TypeMethodDescriptionprotected Collection<Resource> Take all elements except for the lastcountelements.intsize()Efficient size implementation.Methods inherited from class org.apache.tools.ant.types.resources.SizeLimitCollectiongetCount, getValidCount, setCountMethods inherited from class org.apache.tools.ant.types.resources.BaseResourceCollectionWrappercreateIterator, getSizeMethods inherited from class org.apache.tools.ant.types.resources.AbstractResourceCollectionWrapperadd, dieOnCircularReference, getResourceCollection, isCache, isFilesystemOnly, iterator, setCache, toStringMethods inherited from class org.apache.tools.ant.types.DataTypecheckAttributesAllowed, checkChildrenAllowed, circularReference, clone, dieOnCircularReference, dieOnCircularReference, getCheckedRef, getCheckedRef, getCheckedRef, getCheckedRef, getCheckedRef, getDataTypeName, getRefid, invokeCircularReferenceCheck, isChecked, isReference, noChildrenAllowed, pushAndInvokeCircularReferenceCheck, setChecked, setRefid, tooManyAttributesMethods inherited from class org.apache.tools.ant.ProjectComponentgetDescription, getLocation, getProject, log, log, setDescription, setLocation, setProjectMethods inherited from class java.lang.Objectequals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface java.lang.IterableforEach, spliteratorMethods inherited from interface org.apache.tools.ant.types.ResourceCollectionisEmpty, stream
- 
Constructor Details- 
AllButLastpublic AllButLast()
 
- 
- 
Method Details- 
getCollectionTake all elements except for the lastcountelements.- Specified by:
- getCollectionin class- BaseResourceCollectionWrapper
- Returns:
- a Collection of Resources.
 
- 
sizepublic int size()Description copied from class:SizeLimitCollectionEfficient size implementation.- Specified by:
- sizein interface- ResourceCollection
- Overrides:
- sizein class- SizeLimitCollection
- Returns:
- int size
 
 
-