niusouti.com
更多“FileSystem Object有两个方法,分别为CreatText File方法和OpenText File方法。”相关问题
  • 第1题:

    A user reports that they are getting an error when trying to save a video file to a share on a server running Windows Server 2003. The administrator looks at the file and finds that it is 5GB. The administrator checks the server and finds that the server has 100GB of free space. This file needs to be saved on the server.Which of the following should the administrator do to accomplish this?()

    A. Convert the filesystem to EXT3.

    B. Convert the filesystem to VMFS.

    C. Convert the filesystem to NTFS.

    D. Convert the filesystem to FAT32.


    参考答案:C

  • 第2题:

    用面向对象方法设计了一个父类File和两个子类DiskFile和TapeFile,这两个子类继承了其父类的open方法,并给出不同的实现。不同的子类执行open方法时,有不同的行为,这种机制称为( )。

    A.继承
    B.消息传递
    C.多态
    D.关联

    答案:C
    解析:
    本题考查面向对象方法中多态性的基础知识。多态:一个基类的引用符,可以指向多种派生类对象,具有多种不同的形态,这种现象叫多态性。题干里的描述是面向对象的“多态”机制。故正确答案为C

  • 第3题:

    File类中的listFiles()方法说法正确的是()。

    • A、 获取File对象封装的路径下的全部文件和文件夹对象
    • B、 只获取File对象封装的路径下的文件
    • C、 该方法返回File类型数组
    • D、 该方法返回String类型数组

    正确答案:A,C

  • 第4题:

    wait()方法首先是哪个类的方法?()

    • A、 Object
    • B、 Thread.
    • C、 Runnable
    • D、 File

    正确答案:A

  • 第5题:

    File类提供的静态方法有哪些,各有什么用?


    正确答案:创建、复制、删除、移动和打开文件 

  • 第6题:

    An application writes to a log file in the /logs filesystem that is full. After the log file is deleted,‘df’ still shows the filesystem as 100% full.  What is the likely cause of the problem and what will resolve it?()

    • A、The deleted file is still open by the application. The system must be rebooted before ‘df’ will show the reduction in the filesystem.
    • B、The deleted file is still open by the application. The application must be stopped before ‘df’ will show the reduction in the filesystem.
    • C、The filesystem is still marked as full in the /etc/fs.status file. The system must be rebooted before ‘df’ will show the reduction in the filesystem.
    • D、The filesystem is still marked as full in the /etc/fs.status file. The application must be stopped before ‘df’ will show the reduction in the filesystem.

    正确答案:B

  • 第7题:

    A user reports that they are getting an error when trying to save a video file to a share on a server running Windows Server 2003. The administrator looks at the file and finds that it is 5GB. The administrator checks the server and finds that the server has 100GB of free space. This file needs to be saved on the server. Which of the following should the administrator do to accomplish this?()

    • A、Convert the filesystem to EXT3.
    • B、Convert the filesystem to VMFS.
    • C、Convert the filesystem to NTFS.
    • D、Convert the filesystem to FAT32.

    正确答案:C

  • 第8题:

    What is the process for creating an NFS mount between two servers in the same network zone?()

    • A、Export the desired filesystem in the /etc/nfs file, run ’exportfs -a’,create a mount directory on the desired server, and mount the NFS filesystem.
    • B、Run ’exportfs -a’,export the desired filesystem in the /etc/nfs file,create a mount directory on the desired server, and mount the NFS filesystem.
    • C、Export the desired filesystem in the /etc/exports file, run ’exportfs -a’,create a mount directory on the desired server,and mount the NFS filesystem.
    • D、Run ’exportfs -u’,export the desired filesystem in the /etc/exports file, create a mount directory on the desired server,and mount the NFS filesystem.

    正确答案:C

  • 第9题:

    Given that file is a reference to a File object that represents a directory, which code fragments will succeed in obtaining a list of the entries in the directory?()  

    • A、Vector filelist = ((Directory) file).getList();
    • B、String[] filelist = file.directory();
    • C、Enumeration filelist = file.contents();
    • D、String[] filelist = file.list();
    • E、Vector filelist = (new Directory(file)).files();

    正确答案:D

  • 第10题:

    单选题
    wait()方法首先是哪个类的方法?()
    A

     Object

    B

     Thread.

    C

     Runnable

    D

     File


    正确答案: D
    解析: 暂无解析

  • 第11题:

    多选题
    File类中的listFiles()方法说法正确的是()。
    A

    获取File对象封装的路径下的全部文件和文件夹对象

    B

    只获取File对象封装的路径下的文件

    C

    该方法返回File类型数组

    D

    该方法返回String类型数组


    正确答案: C,D
    解析: 暂无解析

  • 第12题:

    单选题
    要新建一个出版物可以采用()方法。
    A

    单击“File/Place”命令

    B

    单击“File/New”命令

    C

    单击“Layout/InsertPages”命令

    D

    单击“File/Open”命令


    正确答案: B
    解析: 暂无解析

  • 第13题:

    The(72)turns the source file into an object file and the(73)turns the object file into an executable file.

    A.translator

    B.compiler

    C.interpreter

    D.linker


    正确答案:B
    解析:译文:编译程序将源文件转换成目标文件,连接程序将目标文件转换成可执行文件。

  • 第14题:

    An application writes to a log file in the /logs filesystem that is full. After the log file is deleted, 'df' still shows the filesystem as 100% full. What is the likely cause of the problem and what will resolve it?()

    • A、The deleted file is still open by the application.The system must be rebooted before'df' will show the reduction in the filesystem.
    • B、The deleted file is still open by the application.The application must be stoppedbefore 'df' will show the reduction in the filesystem.
    • C、The filesystem is still marked as full in the /etc/fs.status file.The system must be rebooted before 'df' will show the reduction in the filesystem.
    • D、The filesystem is still marked as full in the /etc/fs.status file.The application must be stopped before 'df' will show the reduction in the filesystem.

    正确答案:B

  • 第15题:

    File类提供实现文件读写的操作方法。


    正确答案:正确

  • 第16题:

    关于File类中的exists()方法说法错误的是()。

    • A、 判断File对象中封装的路径所对应的文件或者文件夹是否存在
    • B、 此方法返回boolean类型值
    • C、 判断File对象封装的路径是否是相对路径
    • D、 判断File对象封装的路径是否是绝对路径

    正确答案:C,D

  • 第17题:

    下面可打开文件的方法有()

    • A、File对象的OpenAsTextStream方法
    • B、FileSystemObject对象的OpenAsTextStream方法
    • C、File对象的OpenTextFile方法
    • D、TextStream对象的OpenTextFile方法

    正确答案:C

  • 第18题:

    要新建一个出版物可以采用()方法。

    • A、单击“File/Place”命令
    • B、单击“File/New”命令
    • C、单击“Layout/InsertPages”命令
    • D、单击“File/Open”命令

    正确答案:B

  • 第19题:

    Which command(s) will result in the smallest sized backup of the text files contained in the /staticFS filesystem?()  

    • A、tar -cvf file_system.tar /staticFS ; gzip file_system.tar
    • B、tar -xvf /staticFS file_system.tar ; gzip file_system.tar
    • C、tar -cvf /staticFS file_system.tar ; compress file_system.tar
    • D、tar -xvf file_system.tar /staticFS  ; compress file_system.tar

    正确答案:A

  • 第20题:

    A system administrator is unable to unmount a file system. Which is the appropriate command to determine who or what is accessing the file system?()

    • A、who /filesystem
    • B、lsfs /filesystem
    • C、fuser /filesystem
    • D、umount -f /filesystem

    正确答案:C

  • 第21题:

    You are developing an application to create a new file on the local file system.You need to define specific security settings for the file. You must deny the file inheritance of any default security settings during creation.What should you do?()

    • A、Create the file by using a new FileStream object by passing the FileSecurity object as a parameter to the FileStream constructor.
    • B、Create a new FileSecurity object.
    • C、Apply the permissions by using the File class.
    • D、Create a new FileSystem Access Rule object for each permission that you need,and add each rule to the FileSecurity object.
    • E、Create a new FileSystem Audit Rule object and add it to the FileSecurity object.

    正确答案:A,B,D

  • 第22题:

    多选题
    You are developing an application to create a new file on the local file system.You need to define specific security settings for the file. You must deny the file inheritance of any default security settings during creation.What should you do?()
    A

    Create the file by using a new FileStream object by passing the FileSecurity object as a parameter to the FileStream constructor.

    B

    Create a new FileSecurity object.

    C

    Apply the permissions by using the File class.

    D

    Create a new FileSystem Access Rule object for each permission that you need,and add each rule to the FileSecurity object.

    E

    Create a new FileSystem Audit Rule object and add it to the FileSecurity object.


    正确答案: B,E
    解析: 暂无解析

  • 第23题:

    问答题
    File类提供的静态方法有哪些,各有什么用?

    正确答案: 创建、复制、删除、移动和打开文件 
    解析: 暂无解析