Interface ElementWriter<T>
- Type Parameters:
T- The type of the elements to write.
- Functional Interface:
- This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
An
ElementWriter specifies how to write an object to an OutputStream.- Since:
- 1.1
- See Also:
-
Method Summary
Modifier and TypeMethodDescriptionvoidwrite(T el, OutputStream out) Writes the specified element to theOutputStream.
-
Method Details
-
write
Writes the specified element to theOutputStream.- Parameters:
el- The element. The implementation decides if the element may benull.out- The output stream. Must not benull.- Throws:
IOException- If an I/O error occurs.
-