public class FileOpenParams
extends java.lang.Object
Contains the details of a file open request.
Modifier and Type | Field and Description |
---|---|
static java.lang.String |
StreamSeparator |
Constructor and Description |
---|
FileOpenParams(java.lang.String path,
int openAction,
int accessMode,
int fileAttr,
int pid)
Class constructor for Core SMB dialect Open SMB requests
|
FileOpenParams(java.lang.String path,
int openAction,
int accessMode,
int fileAttr,
int gid,
int uid,
int mode,
int pid)
Class constructor for Core SMB dialect Open SMB requests
|
FileOpenParams(java.lang.String path,
int openAction,
int accessMode,
int searchAttr,
int fileAttr,
int allocSize,
long createDate,
int pid)
Class constructor for LanMan SMB dialect OpenAndX requests
|
FileOpenParams(java.lang.String path,
int openAction,
int accessMode,
int attr,
int sharedAccess,
long allocSize,
int createOption,
int rootFID,
int secLevel,
int secFlags,
int pid)
Class constructor for NT SMB dialect NTCreateAndX requests
|
Modifier and Type | Method and Description |
---|---|
int |
getAccessMode()
Return the access mode flags
|
long |
getAllocationSize()
Return the allocation size, or zero if not specified
|
int |
getAttributes()
Return the file attributes
|
int |
getCreateOptions()
Return the create options flags
|
long |
getCreationDateTime()
Return the file creation date/time
|
java.lang.String |
getFullPath()
Return the full path to be opened/created, including the stream
|
int |
getGid()
Return the owner group id
|
int |
getMode()
Return the Unix mode
|
int |
getOpenAction()
Return the open/create file/directory action
All actions are mapped to the FileAction.NTxxx action codes.
|
java.lang.String |
getPath()
Return the path to be opened/created
|
int |
getProcessId()
Return the process id
|
int |
getRootDirectoryFID()
Return the root directory file id, or zero if not specified
|
int |
getSecurityLevel()
Return the security impersonation level.
|
SrvSession |
getSession()
Return the session
|
int |
getSharedAccess()
Return the shared access mode, zero equals allow any shared access
|
java.lang.String |
getStreamName()
Return the stream name
|
java.lang.String |
getSymbolicLinkName()
Return the symbolic link name
|
int |
getTreeId()
Return the tree id
|
int |
getUid()
Return the owner user id
|
boolean |
hasAccessMode(int mode)
Check for a particular access mode
|
boolean |
hasCreateOption(int flag)
Check if the specified create option is enabled, specified in the WinNT class.
|
boolean |
hasCreationDateTime()
Determine if a creation date/time has been specified
|
boolean |
hasGid()
Determine if the group id has been set
|
boolean |
hasMode()
Determine if the mode has been set
|
boolean |
hasSecurityContextTracking()
Determine if the security context tracking flag is enabled
|
boolean |
hasSecurityEffectiveOnly()
Determine if the security effective only flag is enabled
|
boolean |
hasSecurityLevel()
Determine if security impersonation is enabled
|
boolean |
hasSession()
Determine if the session has been set
|
boolean |
hasTreeId()
Check if the tree id has been set
|
boolean |
hasUid()
Determine if the user id has been set
|
boolean |
isAttributesOnlyAccess()
Determine if the file open is to access the file attributes/metadata only
|
boolean |
isDeleteOnClose()
Determine if the file should be deleted when closed
|
boolean |
isDirectory()
Determine if the target of the create/open is a directory
|
int |
isFileType()
Return the file type
|
boolean |
isOverwrite()
Determine if the open mode should overwrite/truncate an existing file
|
boolean |
isReadOnlyAccess()
Determine if the file is to be opened read-only
|
boolean |
isReadWriteAccess()
Determine if the file is to be opened read/write
|
boolean |
isSequentialAccessOnly()
Determine if the file will be accessed sequentially only
|
boolean |
isStream()
Check if a file stream has been specified in the path to be created/opened
|
boolean |
isSymbolicLink()
determine if the target of the create/open is a symbolic link
|
boolean |
isWriteOnlyAccess()
Determine if the file is to be opened write-only
|
boolean |
isWriteThrough()
Determine if write-through mode is enabled (buffering is not allowed if enabled)
|
boolean |
requestBatchOpLock()
Check if a batch oplock was requested
|
boolean |
requestExclusiveOpLock()
Check if an exclusive oplock was requested
|
boolean |
requestExtendedResponse()
Check if an extended response was requested
|
void |
setCreateOption(int flag)
Set a create option flag
|
void |
setFileType(int typ)
Set the file type
|
void |
setMode(int mode)
Set the Unix mode
|
void |
setNTCreateFlags(int createFlags)
Set the NTCreateAndX createFlags
|
void |
setSession(SrvSession sess)
Set the session that is making the open/create request
|
void |
setSymbolicLink(java.lang.String name)
Set the symbolic link name
|
void |
setTreeId(int treeId)
Set the tree id the file open is on
|
java.lang.String |
toString()
Return the file open parameters as a string
|
public static final java.lang.String StreamSeparator
public FileOpenParams(java.lang.String path, int openAction, int accessMode, int fileAttr, int pid)
path
- StringopenAction
- intaccessMode
- int JLAN Access ModefileAttr
- intpid
- intpublic FileOpenParams(java.lang.String path, int openAction, int accessMode, int fileAttr, int gid, int uid, int mode, int pid)
path
- StringopenAction
- intaccessMode
- int JLAN Access ModefileAttr
- intgid
- intuid
- intmode
- intpid
- intpublic FileOpenParams(java.lang.String path, int openAction, int accessMode, int searchAttr, int fileAttr, int allocSize, long createDate, int pid)
path
- StringopenAction
- intaccessMode
- int JLAN Access ModesearchAttr
- intfileAttr
- intallocSize
- intcreateDate
- longpid
- intpublic FileOpenParams(java.lang.String path, int openAction, int accessMode, int attr, int sharedAccess, long allocSize, int createOption, int rootFID, int secLevel, int secFlags, int pid)
path
- StringopenAction
- intaccessMode
- int NT Access Modeattr
- intsharedAccess
- intallocSize
- longcreateOption
- introotFID
- intsecLevel
- intsecFlags
- intpid
- intpublic final java.lang.String getPath()
public final java.lang.String getFullPath()
public final int getAttributes()
public final long getAllocationSize()
public final boolean hasCreationDateTime()
public final long getCreationDateTime()
public final int getOpenAction()
public final int getProcessId()
public final int getRootDirectoryFID()
public final java.lang.String getStreamName()
public final boolean hasCreateOption(int flag)
flag
- intpublic final int getCreateOptions()
public final boolean isStream()
public final boolean isReadOnlyAccess()
public final boolean isWriteOnlyAccess()
public final boolean isReadWriteAccess()
public final boolean isAttributesOnlyAccess()
public final int getAccessMode()
public final boolean isDirectory()
public final int isFileType()
public final boolean isSymbolicLink()
public final java.lang.String getSymbolicLinkName()
public final boolean isSequentialAccessOnly()
public final boolean isDeleteOnClose()
public final boolean isWriteThrough()
public final boolean isOverwrite()
public final int getSharedAccess()
public final boolean hasSecurityLevel()
public final int getSecurityLevel()
public final boolean hasSecurityContextTracking()
public final boolean hasSecurityEffectiveOnly()
public final boolean hasGid()
public final int getGid()
public final boolean hasUid()
public final int getUid()
public final boolean hasMode()
public final int getMode()
public final boolean requestBatchOpLock()
public final boolean requestExclusiveOpLock()
public final boolean requestExtendedResponse()
public final boolean hasSession()
public final SrvSession getSession()
public final boolean hasAccessMode(int mode)
mode
- intpublic final boolean hasTreeId()
public final int getTreeId()
public final void setTreeId(int treeId)
treeId
- intpublic final void setMode(int mode)
mode
- intpublic final void setCreateOption(int flag)
flag
- intpublic final void setNTCreateFlags(int createFlags)
createFlags
- intpublic final void setSession(SrvSession sess)
sess
- SrvSessionpublic final void setFileType(int typ)
typ
- intpublic final void setSymbolicLink(java.lang.String name)
name
- Stringpublic java.lang.String toString()
toString
in class java.lang.Object
Copyright © 2005 - 2010 Alfresco Software, Inc. All Rights Reserved.