edu.ustc.cs.compile.arch
类 Directive

java.lang.Object
  继承者 edu.ustc.cs.compile.arch.AssemblyElement
      继承者 edu.ustc.cs.compile.arch.Directive

public class Directive
extends AssemblyElement

Provides a representation of the directive in the assembly language codes.

A directive consists of a director (represented by Director) and a list of arguments (represented by Directive.Argument).
The examples of representing directives of x86 assembly language and mips assembly language can be respectively found in the descriptions of X86Director and MIPSDirector.


嵌套类摘要
static class Directive.Argument
          This class provides a representation of the argument of the directive in the assembly language codes.
 
字段摘要
private  java.util.List<Directive.Argument> arguments
           
private  Director director
           
 
构造函数摘要
Directive(Director director, java.util.List<Directive.Argument> arguments)
          Constructs an object to represent a directive.
 
方法摘要
 java.util.List<Directive.Argument> arguments()
          gets the arguments of this directive.
 Director director()
          Gets the director of this directive.
 java.lang.String toString()
          returns a string representation of this directive.
 
从类 java.lang.Object 继承的方法
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

字段详细信息

director

private Director director

arguments

private java.util.List<Directive.Argument> arguments
构造函数详细信息

Directive

public Directive(Director director,
                 java.util.List<Directive.Argument> arguments)
Constructs an object to represent a directive.

参数:
director - the director of the directive
arguments - a list of arguments of this directive. It should be null , if the directive has no arguments. The member of this list is of type Argument.
方法详细信息

director

public Director director()
Gets the director of this directive.

返回:
the director of this directive.

arguments

public java.util.List<Directive.Argument> arguments()
gets the arguments of this directive.

返回:
a list of arguments, or null if this directive has no argument. The member of the list is of type Argument.

toString

public java.lang.String toString()
returns a string representation of this directive. The representation consists of the string representation of the director, which followed by a list of the string representation of the arguments seperated by the comma.

覆盖:
java.lang.Object 中的 toString
返回:
a string representation of this directive.