C# Class Microsoft.Cci.Ast.LoopContract

A collection of collections of objects that describe a loop.
Inheritance: Contract, ILoopContract
Datei anzeigen Open project: visualmutator/visualmutator

Private Properties

Property Type Description
GetWrites IEnumerable
LoopContract System.Collections.Generic

Public Methods

Method Description
Dispatch ( ICodeAndContractVisitor visitor ) : void

Calls visitor.Visit(ILoopInvariant).

LoopContract ( IEnumerable invariants, IEnumerable writes ) : System.Collections.Generic

Allocates a collection of collections of objects that describe a loop.

LoopContract ( IEnumerable invariants, IEnumerable writes, IEnumerable variants ) : System.Collections.Generic

Allocates a collection of collections of objects that describe a loop.

MakeCopyFor ( BlockStatement containingBlock ) : LoopContract

Makes a copy of this contract, changing the containing block to the given block.

SetContainingBlock ( BlockStatement containingBlock ) : void

Completes the two stage construction of this object. This allows bottom up parsers to construct an Expression before constructing the containing Expression. This method should be called once only and must be called before this object is made available to client code. The construction code itself should also take care not to call any other methods or property/event accessors on the object until after this method has been called.

Protected Methods

Method Description
CheckForErrorsAndReturnTrueIfAnyAreFound ( ) : bool

Checks for errors and return true if any are found.

Private Methods

Method Description
GetWrites ( ) : IEnumerable
LoopContract ( LoopContract template ) : System.Collections.Generic

A copy constructor that allocates an instance that is the same as the given template.

Method Details

CheckForErrorsAndReturnTrueIfAnyAreFound() protected method

Checks for errors and return true if any are found.
protected CheckForErrorsAndReturnTrueIfAnyAreFound ( ) : bool
return bool

Dispatch() public method

Calls visitor.Visit(ILoopInvariant).
public Dispatch ( ICodeAndContractVisitor visitor ) : void
visitor ICodeAndContractVisitor
return void

LoopContract() public method

Allocates a collection of collections of objects that describe a loop.
public LoopContract ( IEnumerable invariants, IEnumerable writes ) : System.Collections.Generic
invariants IEnumerable A possibly empty or null list of loop invariants.
writes IEnumerable A possibly empty list of expressions that each represents a set of memory locations that may be written to by the body of the loop.
return System.Collections.Generic

LoopContract() public method

Allocates a collection of collections of objects that describe a loop.
public LoopContract ( IEnumerable invariants, IEnumerable writes, IEnumerable variants ) : System.Collections.Generic
invariants IEnumerable A possibly empty or null list of loop invariants.
writes IEnumerable A possibly empty list of expressions that each represents a set of memory locations that may be written to by the body of the loop.
variants IEnumerable A possibly empty list or null list of loop variants.
return System.Collections.Generic

MakeCopyFor() public method

Makes a copy of this contract, changing the containing block to the given block.
public MakeCopyFor ( BlockStatement containingBlock ) : LoopContract
containingBlock BlockStatement
return LoopContract

SetContainingBlock() public method

Completes the two stage construction of this object. This allows bottom up parsers to construct an Expression before constructing the containing Expression. This method should be called once only and must be called before this object is made available to client code. The construction code itself should also take care not to call any other methods or property/event accessors on the object until after this method has been called.
public SetContainingBlock ( BlockStatement containingBlock ) : void
containingBlock BlockStatement
return void