网友您好, 请在下方输入框内输入要搜索的题目:

题目内容 (请给出正确答案)

获取一个不包含路径的文件名的方法为()

  • A、 String getName( )
  • B、 String getPath( )
  • C、 String getAbslutePath( )
  • D、 String getParent( )

参考答案

更多 “获取一个不包含路径的文件名的方法为()A、 String getName( )B、 String getPath( )C、 String getAbslutePath( )D、 String getParent( )” 相关考题
考题 为使下列代码正常运行,应该在下划线处填入的选项是abstract class Person{public Person(String n)!name=n;}public____String getDescription();public String getName(){return name;}private String name;}A.staticB.privateC.abstractD.final

考题 假定程序中有以下语句: answer=MsgBox("String1",,"String2","String3",2) 执行该语句后,将显示一个信息框,此时如果单击“确定”按钮,则answer的值为 ______。A.String1B.String2C.String3D.1

考题 阅读下列代码段 abstract class Person{ public Person(String n){ name=n; } public______String getDescription(); public String getName(){ } private String name; } 在下画线处应填入的修饰符是A.staticB.abstractC.protectedD.final

考题 文件操作中,语句public String getPath()的作用是( )。A.得到一个包含路径的文件名B.得到文件路径名字符串C.得到文件对象的父路径名D.得到文件的上一级目录名

考题 request对象可以使用( )方法获取表单中某输入框提交的信息。A.getParameter(String s)B.getValue(String s)C.getParameterNames(String s)D.getParameterValue(String s)

考题 阅读下面代码 abstract class Person { public Person(String n) { name=n; } public______String getDescription(); public String getName() { return name; } private String name; } 在下画线处应填入的修饰符是A.staticB.abstractC.protectedD.final

考题 获取一个不包含路径的文件名的方法为( )。A.String getAbsolutePath();B.String getParent();C.String getName();D.String getPath();

考题 获取一个不包含路径的文件名的方法为( )。A.String gctName():B. String getPath():C. StringgetAbslutePath();D. StringgetParent():

考题 为使下列代码正常运行,应该在下画线处填入的选项是( )。 abstract class person{ public Person(String n){ name=n: } Public String getDescription; public String getName{ return name; } private string name; }A.staticB.privateC.abstractD.final

考题 下面哪个方法设置MIME类型?()A、setHeader(String headerName,String headerValue)B、setContentType(String mimeType)C、setContentLength(int length)D、addCookie(Cookie c)E、addHeader(String name,String value)

考题 执行以下代码后,下面哪些描述是正确的() public  class  Student{  private String name = “Jema”;  public void setName(String name){  this.name = name;  }  public String getName(){  return this.name;  }  public static void main(String[] args){  Student s;  System.out.println(s.getName()); } }A、输出nullB、第10行编译报错C、第11行编译报错D、输出Jema

考题 public class Employee{   private String name;   public Employee(String name){   this.name = name;  }   public String getName(){   return name;  }  }   public class Manager extends Employee{   private String department;   public Manager(String name,String department){   this.department = department;   super(name); (应于上一行掉位置)   System.out.println(getName());  }  }   Super的位置是否在方法的首行   执行语句new Manager(“smith”,”SALES”)后程序的输出是哪项?()A、 smithB、 nullC、 SALESD、 编译错误

考题 public class Employee{       private String name;  public Employee(String name){           this.name = name;      }  public String getName(){         return name;      } }  public class Manager extends Employee{       private String department;  public Manager(String name,String department){          this.department = department;          super(name);  System.out.println(getName());      }  }  执行语句new Manager(“smith”,”SALES”)后程序的输出是哪项?() A、 smithB、 nullC、 SALESD、 编译错误

考题 下列不是 String 类的方法的是()A、charAt(int index)B、indexOf(String s)C、beginWith(String s)D、endsWith(String s)

考题 File类的方法中,用于列举某目录下的子目录及文件的方法是()A、long length()B、long lastModified()C、String [] list()D、String getName()

考题 在C#中,下列哪条语句能创建一个具有3个初始值为""的元素的字符串数组?()A、string StrList[3]("");B、string[3] StrList={"","",""};C、string[] StrList={"","",""};D、string[] StrList=new string[3];

考题 在J2EE中,request对象的()方法可以获取页面请求中一个表单组件对应多个值时的用户的请求数据。A、String[] getParameterValues(Stringname)B、String[] getParameter(Stringname)C、String getParameter(Stringname)D、String getParameterValuses(Stringname)

考题 request对象可以使用()方法获取表单中某输入框提交的信息。A、getParameter(String s)B、getValue(String s)C、getParameterNames(String s)D、getParameterValue(String s)

考题 在JAVA EE中,request对象的()方法可以获取页面请求中一个表单组件对应多个值时的用户的请求数据。A、String getParameter(String name)B、String[] getParameter(String name)C、String getParameterValuses(String name)D、String[] getParameterValues(String name)

考题 Which gets the name of the parent directory file “file.txt”?()A、 String name= File.getParentName(“file.txt”);B、 String name= (new File(“file.txt”)).getParent();C、 String name = (new File(“file.txt”)).getParentName();D、 String name= (new File(“file.txt”)).getParentFile();E、 Directory dir=(new File (“file.txt”)).getParentDir();  String name= dir.getName();

考题 public class Employee{   private String name;   public Employee(String name){   this.name = name;  }   public String getName(){   return name;  }  }   public class Manager extends Employee{   public Manager(String name){   System.out.println(getName());  }  }   执行语句new Manager(“smith”)后程序的输出是哪项?() A、 smithB、 nullC、 编译错误D、 name

考题 单选题request对象可以使用()方法获取表单中某输入框提交的信息。A getParameter(String s)B getValue(String s)C getParameterNames(String s)D getParameterValue(String s)

考题 单选题public class Employee{       private String name;  public Employee(String name){           this.name = name;      }  public String getName(){         return name;      } }  public class Manager extends Employee{       public Manager(String name){          System.out.println(getName());      } }  执行语句new Manager(“smith”)后程序的输出是哪项?()A  smithB  nullC  编译错误D  name

考题 单选题获取一个不包含路径的文件名的方法为()A  String getName( )B  String getPath( )C  String getAbslutePath( )D  String getParent( )

考题 单选题执行以下代码后,下面哪些描述是正确的() public  class  Student{  private String name = “Jema”;  public void setName(String name){  this.name = name;  }  public String getName(){  return this.name;  }  public static void main(String[] args){  Student s;  System.out.println(s.getName()); } }A 输出nullB 第10行编译报错C 第11行编译报错D 输出Jema

考题 单选题Which gets the name of the parent directory file “file.txt”?()A  String name= File.getParentName(“file.txt”);B  String name= (new File(“file.txt”)).getParent();C  String name = (new File(“file.txt”)).getParentName();D  String name= (new File(“file.txt”)).getParentFile();E  Directory dir=(new File (“file.txt”)).getParentDir();  String name= dir.getName();

考题 单选题在JAVA EE中,request对象的()方法可以获取页面请求中一个表单组件对应多个值时的用户的请求数据。A String getParameter(String name)B String[] getParameter(String name)C String getParameterValuses(String name)D String[] getParameterValues(String name)