opencard.tests.service
Class CreateFile
java.lang.Object
|
+--opencard.tests.testframe.TestCase
|
+--opencard.tests.service.CreateFile
- public class CreateFile
- extends TestCase
- implements java.lang.Runnable
Create a file or directory on the smartCard.
If the program runs without arguments then the card has to include the card's layout in
the subdirectory testlayout/lay40-a. A corresponding layout on the card is required to run
the program with arguments.
java CreateFile ")
|
Constructor Summary |
CreateFile()
|
CreateFile(java.lang.String FileID,
int FileLength,
int[] AccArr,
int RecordSize,
int FileType,
java.lang.String DirID)
Constructor initiates these parameters to appropiate values . |
|
Method Summary |
boolean |
create(java.lang.String FileID,
int FileLength,
int[] AccArr,
int RecordSize,
int FileType,
java.lang.String DirID)
Create a file or directory on the smartCard. |
static int |
getRetCode()
|
static void |
main(java.lang.String[] args)
Starts the program.
|
void |
run()
run method for multithreading |
static void |
setRetCode(int rc)
|
int |
start(java.lang.String[] args)
|
| Methods inherited from class java.lang.Object |
clone,
equals,
finalize,
getClass,
hashCode,
notify,
notifyAll,
toString,
wait,
wait,
wait |
CreateFile
public CreateFile()
CreateFile
public CreateFile(java.lang.String FileID,
int FileLength,
int[] AccArr,
int RecordSize,
int FileType,
java.lang.String DirID)
- Constructor initiates these parameters to appropiate values .
- Parameters:
FileID - File to be created (e.g. 1003 - File 1003 will be created)FileLength - Length of the File (in Bytes)AccArr - Array of access conditions: {, , , , }
Each condition can have the values 0 (ALWAYS), 1 (NEVER) or 2 (CHV)RecordSize - Size of one Record (in Bytes)FileType - Type of the File to be gegerated: 0 - Flat File, 1 - Record File, 2 - DirectoryDirID - Directory where the file will be created.
main
public static void main(java.lang.String[] args)
- Starts the program.
The passed arguments are appropiate evaluated.
start
public int start(java.lang.String[] args)
- Overrides:
- start in class TestCase
run
public void run()
- run method for multithreading
- Specified by:
- run in interface java.lang.Runnable
create
public boolean create(java.lang.String FileID,
int FileLength,
int[] AccArr,
int RecordSize,
int FileType,
java.lang.String DirID)
- Create a file or directory on the smartCard.
- Parameters:
FileID - File to be created (e.g. 1003 - File 1003 will be created)FileLength - Length of the File (in Bytes)AccArr - Array of access conditions: {, , , , }
Each condition can have the values 0 (ALWAYS), 1 (NEVER) or 2 (CHV)RecordSize - Size of one Record (in Bytes)FileType - Type of the File to be gegerated: 0 - Flat File, 1 - Record File, 2 - DirectoryDirID - Directory where the file will be created.
setRetCode
public static void setRetCode(int rc)
getRetCode
public static int getRetCode()
|