@Override public String toString() { final StringBuilder sb = new StringBuilder("["); if (has(Flag.SIZE)) sb.append("size=").append(size).append(";"); if (has(Flag.UIDGID)) sb.append("uid=").append(uid).append(",gid=").append(gid).append(";"); if (has(Flag.MODE)) sb.append("mode=").append(mode.toString()).append(";"); if (has(Flag.ACMODTIME)) sb.append("atime=").append(atime).append(",mtime=").append(mtime).append(";"); if (has(Flag.EXTENDED)) sb.append("ext=").append(ext); sb.append("]"); return sb.toString(); }
public byte[] toBytes() { Buffer.PlainBuffer buf = new Buffer.PlainBuffer(); buf.putUInt32(mask); if (has(Flag.SIZE)) buf.putUInt64(size); if (has(Flag.UIDGID)) { buf.putUInt32(uid); buf.putUInt32(gid); } if (has(Flag.MODE)) buf.putUInt32(mode.getMask()); if (has(Flag.ACMODTIME)) { buf.putUInt32(atime); buf.putUInt32(mtime); } if (has(Flag.EXTENDED)) { buf.putUInt32(ext.size()); for (Entry<String, String> entry : ext.entrySet()) { buf.putString(entry.getKey()); buf.putString(entry.getValue()); } } return buf.getCompactData(); }
private void copyAttributes(final RemoteResourceInfo remote, final LocalDestFile local) throws IOException { final FileAttributes attrs = remote.getAttributes(); local.setPermissions(attrs.getMode().getPermissionsMask()); if (attrs.has(FileAttributes.Flag.ACMODTIME)) { local.setLastAccessedTime(attrs.getAtime()); local.setLastModifiedTime(attrs.getMtime()); } }
@Override public String toString() { final StringBuilder sb = new StringBuilder("["); if (has(Flag.SIZE)) sb.append("size=").append(size).append(";"); if (has(Flag.UIDGID)) sb.append("uid=").append(size).append(",gid=").append(gid).append(";"); if (has(Flag.MODE)) sb.append("mode=").append(mode.toString()).append(";"); if (has(Flag.ACMODTIME)) sb.append("atime=").append(atime).append(",mtime=").append(mtime).append(";"); if (has(Flag.EXTENDED)) sb.append("ext=").append(ext); sb.append("]"); return sb.toString(); }
@Override public String toString() { final StringBuilder sb = new StringBuilder("["); if (has(Flag.SIZE)) sb.append("size=").append(size).append(";"); if (has(Flag.UIDGID)) sb.append("uid=").append(uid).append(",gid=").append(gid).append(";"); if (has(Flag.MODE)) sb.append("mode=").append(mode.toString()).append(";"); if (has(Flag.ACMODTIME)) sb.append("atime=").append(atime).append(",mtime=").append(mtime).append(";"); if (has(Flag.EXTENDED)) sb.append("ext=").append(ext); sb.append("]"); return sb.toString(); }
public byte[] toBytes() { Buffer.PlainBuffer buf = new Buffer.PlainBuffer(); buf.putUInt32(mask); if (has(Flag.SIZE)) buf.putUInt64(size); if (has(Flag.UIDGID)) { buf.putUInt32(uid); buf.putUInt32(gid); } if (has(Flag.MODE)) buf.putUInt32(mode.getMask()); if (has(Flag.ACMODTIME)) { buf.putUInt32(atime); buf.putUInt32(mtime); } if (has(Flag.EXTENDED)) { buf.putUInt32(ext.size()); for (Entry<String, String> entry : ext.entrySet()) { buf.putString(entry.getKey()); buf.putString(entry.getValue()); } } return buf.getCompactData(); }
public byte[] toBytes() { Buffer.PlainBuffer buf = new Buffer.PlainBuffer(); buf.putUInt32(mask); if (has(Flag.SIZE)) buf.putUInt64(size); if (has(Flag.UIDGID)) { buf.putUInt32(uid); buf.putUInt32(gid); } if (has(Flag.MODE)) buf.putUInt32(mode.getMask()); if (has(Flag.ACMODTIME)) { buf.putUInt32(atime); buf.putUInt32(mtime); } if (has(Flag.EXTENDED)) { buf.putUInt32(ext.size()); for (Entry<String, String> entry : ext.entrySet()) { buf.putString(entry.getKey()); buf.putString(entry.getValue()); } } return buf.getCompactData(); }
private void copyAttributes(final RemoteResourceInfo remote, final LocalDestFile local) throws IOException { final FileAttributes attrs = remote.getAttributes(); local.setPermissions(attrs.getMode().getPermissionsMask()); if (attrs.has(FileAttributes.Flag.ACMODTIME)) { local.setLastAccessedTime(attrs.getAtime()); local.setLastModifiedTime(attrs.getMtime()); } }
private void copyAttributes(final RemoteResourceInfo remote, final LocalDestFile local) throws IOException { final FileAttributes attrs = remote.getAttributes(); local.setPermissions(attrs.getMode().getPermissionsMask()); if (attrs.has(FileAttributes.Flag.ACMODTIME)) { local.setLastAccessedTime(attrs.getAtime()); local.setLastModifiedTime(attrs.getMtime()); } }