Hi,
Prior to Java 7, we'd use
FileOutputStream fos = new FileOutputStream(f);
fos.write(...)
fos.getFD().sync();
As of Java 7, we can say:
OutputStream os = Files.newOutputStream(path, StandardOpenOption.SYNC);
Regarding the behavior and the integrity, which one is more recommended?
Or, are bo
Hi,
I have a question regarding the method references in Java 8. Let's say that
I have a class:
class MyClass {
Object doSomething(Object o);
}
And, I'm using the method reference MyClass::doSomething in a call
such as SomeOtherClass.doAnotherThing(p,
MyClass::doSomething). In this call, let
?
On Wed, Jun 12, 2013 at 10:22 AM, Florian Weimer wrote:
> On 06/11/2013 11:50 PM, Behrooz Nobakht wrote:
>
>> My question is that how should the method doAnotherThing be declared?
>>
>
> In most cases, it is appropriate to define an interface with a single
> metho
not, any suggestion to approach it? Such as MethodHandle?
Thanks again!
Behrooz
On Wed, Jun 12, 2013 at 11:12 AM, Remi Forax wrote:
> On 06/12/2013 10:35 AM, Behrooz Nobakht wrote:
>
>> Thanks for the reply. Just a follow-up question regarding the fact that
>> method r