mirror of
https://github.com/AppleCommander/AppleCommander.git
synced 2024-06-17 05:29:38 +00:00
23 lines
608 B
Java
23 lines
608 B
Java
|
package io.github.applecommander.acx.fileutil;
|
||
|
|
||
|
import java.util.Optional;
|
||
|
|
||
|
import com.webcodepro.applecommander.storage.os.nakedos.NakedosFileEntry;
|
||
|
|
||
|
public class NakedosFileEntryReader implements FileEntryReader {
|
||
|
private NakedosFileEntry fileEntry;
|
||
|
|
||
|
public NakedosFileEntryReader(NakedosFileEntry fileEntry) {
|
||
|
this.fileEntry = fileEntry;
|
||
|
}
|
||
|
|
||
|
@Override
|
||
|
public Optional<String> getFilename() {
|
||
|
return Optional.of(fileEntry.getFilename());
|
||
|
}
|
||
|
@Override
|
||
|
public Optional<byte[]> getFileData() {
|
||
|
return Optional.of(fileEntry.getFileData());
|
||
|
}
|
||
|
}
|