com.mindbright.ssh2
public static final class SSH2SFTP.FileAttributes extends java.lang.Object
SSH2SFTPClient
Modifier and Type | Field and Description |
---|---|
int |
atime
Time of last access
|
int |
gid
gid of file
|
boolean |
hasModTime
True if the mod time fiels has been initialized
|
boolean |
hasName
True if the name field has been initialized
|
boolean |
hasPermissions
True if the permissions field has been initialized
|
boolean |
hasSize
True if the size field has been initialized
|
boolean |
hasUserGroup
True if the user and group fields has been initialized
|
java.lang.String |
ldest
Only valid for symbolic links, the name the link points at
|
int |
mtime
Time of last modification
|
java.lang.String |
name
Name of file
|
int |
permissions
Permissions flags
|
static int |
S_IFBLK
Block device flag, set if this is a block device
|
static int |
S_IFCHR
Character device flag, set if this is a character device
|
static int |
S_IFDIR
Directory flag, set if this is a directory
|
static int |
S_IFIFO
FIFO flag, set if this is a FIFO pipe
|
static int |
S_IFLNK
Link flag, set if this is a symbolic link
|
static int |
S_IFMT
Format mask, used to mask off the format flags from the mode
|
static int |
S_IFREG
Regular file flag, set if this is a regular file
|
static int |
S_IFSOCK
Socket flag, set if this is a socket
|
static int |
S_IRGRP
Group read rights bit
|
static int |
S_IROTH
Other read rights bit
|
static int |
S_IRUSR
User (owner) read rights bit
|
static int |
S_ISGID
set-gid (SGID) flag
|
static int |
S_ISUID
set-uid (SUID) flag
|
static int |
S_IWGRP
Group write rights bit
|
static int |
S_IWOTH
Other write rights bit
|
static int |
S_IWUSR
User (owner) write rights bit
|
static int |
S_IXGRP
Group execute rights bit
|
static int |
S_IXOTH
Other execute rights bit
|
static int |
S_IXUSR
User (owner) execute rights bit
|
long |
size
Size of file
|
int |
uid
uid of file
|
Constructor and Description |
---|
SSH2SFTP.FileAttributes() |
Modifier and Type | Method and Description |
---|---|
boolean |
isBlock()
Returns true if this is a block device.
|
boolean |
isCharacter()
Returns true if this is a character device.
|
boolean |
isDirectory()
Returns true if this is a directory.
|
boolean |
isFifo()
Returns true if this is a FIFO pipe.
|
boolean |
isFile()
Returns true if this is a regular file.
|
boolean |
isLink()
Returns true if this is a symbolic link.
|
boolean |
isSGID()
Returns true if this object has the setgid flag set.
|
boolean |
isSocket()
Returns true if this is a socket.
|
boolean |
isSUID()
Returns true if this object has the setuid flag set.
|
java.lang.String |
modTimeString()
Print modification time in a format similar to that of
ls -l . |
java.lang.String |
permString()
Generate the permissions part of the
ls -l
simulated string. |
java.lang.String |
toString()
Return a string identifying the file.
|
java.lang.String |
toString(java.lang.String name)
Return a string identifying the file.
|
public static final int S_IFMT
public static final int S_IFSOCK
public static final int S_IFLNK
public static final int S_IFREG
public static final int S_IFBLK
public static final int S_IFDIR
public static final int S_IFCHR
public static final int S_IFIFO
public static final int S_ISUID
public static final int S_ISGID
public static final int S_IRUSR
public static final int S_IWUSR
public static final int S_IXUSR
public static final int S_IRGRP
public static final int S_IWGRP
public static final int S_IXGRP
public static final int S_IROTH
public static final int S_IWOTH
public static final int S_IXOTH
public boolean hasName
public boolean hasSize
public boolean hasUserGroup
public boolean hasPermissions
public boolean hasModTime
public java.lang.String name
public java.lang.String ldest
public long size
public int uid
public int gid
public int permissions
public int atime
public int mtime
public java.lang.String toString()
ls -l
.toString
in class java.lang.Object
public java.lang.String toString(java.lang.String name)
ls -l
.name
- name of file to printpublic java.lang.String permString()
ls -l
simulated string.public java.lang.String modTimeString()
ls -l
. That is for dates whiel is less than
six months old "MMM dd hh:mm" and for older dates "MMM dd yyyy".public boolean isSocket()
public boolean isLink()
public boolean isFile()
public boolean isBlock()
public boolean isDirectory()
public boolean isCharacter()
public boolean isFifo()
public boolean isSUID()
public boolean isSGID()