ERROR - UnsupportedOperationException - Possible Causes of UnsupportedOperationException

Exception Thrown By:Cause
ClassMethod
AbstractCollection public boolean add(E e)if the add operation is not supported by this collection
AbstractCollection public boolean remove(Object o)if the remove operation is not supported by this collection
AbstractCollection public boolean addAll(Collection c)if the add operation is not supported by this collection
AbstractCollection public boolean removeAll(Collection c)if the remove operation is not supported by this collection
AbstractCollection public boolean retainAll(Collection c)if the retain operation is not supported by this collection
AbstractCollection public void clear()if the clear operation is not supported by this collection
AbstractMap public V remove(Object key)if the remove operation is not supported by this map
AbstractMap public void clear()if the clear operation is not supported by this mapkey
ArrayBlockingQueue public int drainTo(Collection c)if addition of elements is not supported by the specified collection
CertPathBuilder public final CertPathChecker
getRevocationChecker()
if the service provider does not support this method
CertPathBuilderSpi public CertPathChecker
engineGetRevocationChecker()
if this method is not supported
CertPathValidator public final CertPathChecker
getRevocationChecker()
if the service provider does not support this method
CertPathValidatorSpi public CertPathChecker
engineGetRevocationChecker()
if this method is not supported
CertificateFactorySpi public Iterator engineGetCertPathEncodings()if the method is not supported
Charset public abstract CharsetEncoder newEncoder()If this charset does not support encoding
CharsetDecoder public boolean isCharsetDetected()If this decoder does not implement an auto detecting charsetdetecteddetecting charset then this method returns the actual charset once it has been detected.
ChoiceCallback public void
setSelectedIndexes(int[] selections)
if multiple selections are not allowed
Collections public static void reverse(List list)if the specified list or its list iterator does not support the set operation
Collections public static void shuffle(List list)if the specified list or its list iterator does not support the set operation
DatagramChannel public static DatagramChannel
open(ProtocolFamily family)
If the specified protocol family is not supported.
Date public Instant toInstant()if this method is invoked
DelayQueue public int drainTo(Collection c)if addition of elements is not supported by the specified collection
Desktop public void mail()if the current platform does not support the Desktop.Action.MAIL action
DirectColorModel public int getRGB(Object inData)
DocumentBuilder public Schema getSchema()When implementation does not override this method
DocumentBuilder public boolean isXIncludeAware()When implementation does not override this method
Duration public abstract int
 compare(Duration duration)
If the underlying implementation cannot reasonably process the request
Duration public boolean
isLongerThan(Duration duration)
If the underlying implementation cannot reasonably process the request
Duration public boolean
isShorterThan(Duration duration)
If the underlying implementation cannot reasonably process the request
Duration public boolean equals(Object duration)If the underlying implementation cannot reasonably process the request
FileStore public abstract Object
getAttribute(String attribute)
if the attribute view is not available or it does not supportreading the attribute
FileSystem public abstract UserPrincipalLookupService
 getUserPrincipalLookupService()
If this FileSystem does not does have a lookup service
FileSystem public abstract WatchService
 newWatchService()
If this FileSystem does not support watching file system objects for changes and events. 
FileSystemProvider public Path readSymbolicLink(Path link)if the implementation does not support symbolic links
Files public static Path
 readSymbolicLink(Path link)
if the implementation does not support symbolic links
ImageWriteParam public int getTilingMode()
ImageWriteParam public Dimension[] getPreferredTileSizes()if the plug in does not support tiling
ImageWriteParam public void unsetTiling()if the plug in does not support tiling.
ImageWriteParam public int getTileWidth()if the plug in does not support tiling.
ImageWriteParam public int getTileHeight()if the plug in does not support tiling.
ImageWriteParam public int getTileGridXOffset()if the plug in does not support tiling.
ImageWriteParam public int getTileGridYOffset()if the plug in does not support tiling.
ImageWriteParam public void setProgressiveMode(int mode)if the writer does not support progressive encoding.
ImageWriteParam public int getProgressiveMode()if the writer does not support progressive encoding.
ImageWriteParam public void setCompressionMode(int mode)if the writer does not support compression
ImageWriteParam public int getCompressionMode()if the writer does not support compression.
ImageWriteParam public String[] getCompressionTypes()if the writer does not support compression
ImageWriteParam public void
setCompressionType(String compressionType)
if the writer does not support compression.
ImageWriteParam public String getCompressionType()if the writer does not support compression.
ImageWriteParam public void unsetCompression()if the plug in does not support compression.
ImageWriteParam public String
getLocalizedCompressionTypeName()
if the writer does not support compression.
ImageWriteParam public boolean isCompressionLossless()if the writer does not support compression.
ImageWriteParam public void
setCompressionQuality(float quality)
if the writer does not support compression.
ImageWriteParam public float getCompressionQuality()if the writer does not support compression.
ImageWriteParam public float getBitRate(float quality)if the writer does not support compression.
ImageWriteParam public String[]
getCompressionQualityDescriptions()
if the writer does not support compression.
ImageWriteParam public float[]
getCompressionQualityValues()
if the writer does not support compression.
InputContext public void
setCompositionEnabled(boolean enable)
if there is no current input method available or the current input method does not support the enabling/disabling operation
InputContext public boolean isCompositionEnabled()if there is no current input method available or the current input method does not support checking whether it is enabled for composition
InputContext public void reconvert()if there is no current input method available or the current input method does not support the reconversion operation
JAXBContext public  Binder createBinder(Class domType)
JAXBContext public JAXBIntrospector createJAXBIntrospector()Calling this method on JAXB 1.0 implementations will throw an UnsupportedOperationException
LinkedBlockingDeque public int drainTo(Collection c)if addition of elements is not supported by the specified collection
LinkedBlockingQueue public int drainTo(Collection c)if addition of elements is not supported by the specified collection
NumberFormat public Currency getCurrency()if the number format class doesn't implement currency formatting
NumberFormat public void setCurrency(Currency currency)if the number format class doesn't implement currency formatting
NumberFormat public RoundingMode getRoundingMode()The default implementation always throws this e
NumberFormat public void
setRoundingMode(RoundingMode roundingMode)
The default implementation always throws this e
PriorityBlockingQueue public int drainTo(Collection c)if addition of elements is not supported by the specified collection
ReentrantRead
WriteLock.ReadLock
public Condition newCondition()
SAXParser public Schema getSchema()When implementation does not override this method
SAXParser public boolean isXIncludeAware()When implementation does not override this method
SSLContext public final SSLEngine createSSLEngine()if the underlying providerdoes not implement the operation.
SSLContext public final SSLParameters getDefaultSSLParameters()if the default SSL parameters could not be obtained
SSLContext public final SSLParameters getSupportedSSLParameters()if the supported SSL parameters could not be obtained
SSLEngine public SSLSession getHandshakeSession()if the underlying provider does not implement the operation.
Scanner public void remove()if this method is invoked
SchemaFactory public abstract Schema newSchema()If this operation is not supported by the callee.
SelectorProvider public abstract DatagramChannel
 openDatagramChannel(ProtocolFamily family)
If the specified protocol family is not supported.
StAXResult public void setSystemId(String systemId)Is always thrown by this method
StAXSource public void setSystemId(String systemId)Is always thrown by this method
SynchronousQueue public int drainTo(Collection c)if addition of elements is not supported by the specified collection
ThreadInfo public long getWaitedTime()if the Java virtual machine does not support this operation
Time public Instant toInstant()if this method is invoked
UUID public long timestamp()If this UUID is not a version 1 based UUID.
UUID public int clockSequence()If this UUID is not a version 1 based UUID
UUID public long node()If this UUID is not a version 1 based UUID.