TypeInst function

TypeInst

TypeInst

Create type instantiation with indices, etc.

Examples

TypeInst$new(type = Type$new(base_type = "int", kind = "par" ,dim = 1), domain = Set$new(IntSetVal$new(2,5)))

Super class

rminizinc::Expression -> TypeInst

Public fields

  • .indExpr: the index expression

  • .domain: the domain of possible values to be taken

  • .type: the type information

Active bindings

  • .indExpr: the index expression

  • .domain: the domain of possible values to be taken

  • .type: the type information

Methods

Public methods

Method new()

constructor

Usage

TypeInst$new(type, indexExprVec = NULL, domain = NULL)

Arguments

  • type: type of declaration

  • indexExprVec: expression list of indices

  • domain: the domain of decision variables

Method getDomain()

get the variable domain

Usage

TypeInst$getDomain()

Method setDomain()

set the variable domain

Usage

TypeInst$setDomain(dom)

Arguments

  • dom: domain expression to be set

Method ranges()

return the index expression vector

Usage

TypeInst$ranges()

Method isArray()

check if it's an array

Usage

TypeInst$isArray()

Method type()

return the type information

Usage

TypeInst$type()

Method clone()

The objects of this class are cloneable with this method.

Usage

TypeInst$clone(deep = FALSE)

Arguments

  • deep: Whether to make a deep clone.

  • Maintainer: Akshit Achara
  • License: Mozilla Public License Version 2.0
  • Last published: 2021-10-15