Tutorials
Courses
Data Structure
Java
Python
HTML
Interview Preparation
DSA
Practice Problems
C
C++
Java
Python
JavaScript
Data Science
Machine Learning
Courses
Linux
DevOps
SQL
Web Development
System Design
Aptitude
GfG Premium
Similar Topics
Web Technologies
37.4K+ articles
DSA
22.8K+ articles
Python
21.3K+ articles
Experiences
16.6K+ articles
Interview Experiences
14.2K+ articles
JavaScript
12.2K+ articles
School Learning
11.5K+ articles
Java
10.8K+ articles
Java-Functions
4.2K+ articles
Java-NIO package
230+ articles
Java-Buffer
17 posts
Recent Articles
Popular Articles
Buffer capacity() method in Java with Examples
Last Updated: 18 July 2019
The capacity() method of java.nio.Buffer Class is used to return this buffer's capacity.Syntax:public final int capacity()Return Value: The capacity of this bufferBelow ar...
read more
Java
Java-Functions
Java-NIO package
Java-Buffer
Buffer position() methods in Java with Examples
Last Updated: 18 July 2019
The position(int newPosition) method of java.nio.Buffer Class is used to set this buffer's position. If the mark is defined and larger than the new position then it is dis...
read more
Java
Java-Functions
Java-NIO package
Java-Buffer
Buffer mark() methods in Java with Examples
Last Updated: 04 February 2022
The mark() method of java.nio.Buffer Class is used to set this buffer's mark at its position.Syntax:public Buffer mark()Return Value: This method returns this buffer.Below...
read more
Java
Java-Functions
Java-NIO package
Java-Buffer
Buffer clear() methods in Java with Examples
Last Updated: 18 July 2019
The clear() method of java.nio.ByteBuffer Class is used to clear this buffer. The position is set to zero, the limit is set to the capacity, and the mark is discarded. Inv...
read more
Java
Java-Functions
Java-NIO package
Java-Buffer
Buffer duplicate() method in Java with Examples
Last Updated: 06 September 2019
The duplicate() method of java.nio.Buffer class is used to create a new buffer that shares this buffer's content. The content of the new buffer will be that of this buffer...
read more
Java
Java-Functions
Java-NIO package
Java-Buffer
Buffer flip() methods in Java with Examples
Last Updated: 18 July 2019
The flip() method of java.nio.ByteBuffer Class is used to flip this buffer. The limit is set to the current position and then the position is set to zero. If the mark is d...
read more
Java
Java-Functions
Java-NIO package
Java-Buffer
Buffer hasArray() methods in Java with Examples
Last Updated: 19 January 2023
The hasArray() method of java.nio.Buffer class is used to tell whether or not this buffer is backed by an accessible array. If this method returns true then the array and ...
read more
Java
Java-Functions
Java-NIO package
Java-Buffer
Buffer hasRemaining() methods in Java with Examples
Last Updated: 22 October 2022
The hasRemaining() method of java.nio.Buffer class is used to tell whether there are any elements between the current position and the limit.Syntax:public final boolean ha...
read more
Java
Java-Functions
Java-NIO package
Java-Buffer
Buffer isDirect() methods in Java with Examples
Last Updated: 16 July 2019
The isDirect() method of java.nio.Buffer Class is used to tell whether or not this buffer is direct.Syntax:public abstract boolean isDirect()Return Value: This method retu...
read more
Java
Java-Functions
Java-NIO package
Java-Buffer
Buffer isReadOnly() methods in Java with Examples
Last Updated: 16 July 2019
The isReadOnly() method of java.nio.Buffer class is used to tell whether or not this buffer is read-only.Syntax:public abstract boolean isReadOnly()Returns: This method wi...
read more
Java
Java-Functions
Java-NIO package
Java-Buffer
Buffer limit() methods in Java with Examples
Last Updated: 16 July 2019
The limit() method of java.nio.Buffer Class is used to set this buffer's limit. If the position is larger than the new limit then it is set to the new limit. If the mark i...
read more
Java
Java-Functions
Java-NIO package
Java-Buffer
Buffer remaining() methods in Java with Examples
Last Updated: 16 July 2019
The remaining() method of java.nio.Buffer Class is used to return the number of elements between the current position and the limit. Syntax:public final int remaining()Ret...
read more
Java
Java-Functions
Java-NIO package
Java-Buffer
Buffer reset() methods in Java with Examples
Last Updated: 04 February 2022
The reset() method of java.nio.Buffer Class is used to reset this buffer's position to the previously-marked position. Invoking this method neither changes nor discards th...
read more
Java
Java-Functions
Java-NIO package
Java-Buffer
Buffer rewind() methods in Java with Examples
Last Updated: 23 July 2019
The rewind() method of java.nio.ByteBuffer Class is used to rewind this buffer. The position is set to zero and the mark is discarded. Invoke this method before a sequence...
read more
Java
Java-Functions
Java-NIO package
Java-Buffer
java.nio.Buffer Class in Java
Last Updated: 03 February 2022
The Buffer class provides a buffer or a container for data chunks of specific primitive types. A finite sequence of elements is stored linearly in a buffer.Important prope...
read more
Java
Picked
Java-NIO package
Java-Classes
Java-Buffer
1
2
We use cookies to ensure you have the best browsing experience on our website. By using our site, you acknowledge that you have read and understood our
Cookie Policy
&
Privacy Policy
Got It !