Z3
Public Member Functions
SeqRef Class Reference
+ Inheritance diagram for SeqRef:

Public Member Functions

def sort (self)
 
def __add__ (self, other)
 
def __radd__ (self, other)
 
def __getitem__ (self, i)
 
def is_string (self)
 
def is_string_value (self)
 
def as_string (self)
 
- Public Member Functions inherited from ExprRef
def as_ast (self)
 
def get_id (self)
 
def sort (self)
 
def sort_kind (self)
 
def __eq__ (self, other)
 
def __hash__ (self)
 
def __ne__ (self, other)
 
def params (self)
 
def decl (self)
 
def num_args (self)
 
def arg (self, idx)
 
def children (self)
 
- Public Member Functions inherited from AstRef
def __init__ (self, ast, ctx=None)
 
def __del__ (self)
 
def __deepcopy__ (self, memo={})
 
def __str__ (self)
 
def __repr__ (self)
 
def __eq__ (self, other)
 
def __hash__ (self)
 
def __nonzero__ (self)
 
def __bool__ (self)
 
def sexpr (self)
 
def as_ast (self)
 
def get_id (self)
 
def ctx_ref (self)
 
def eq (self, other)
 
def translate (self, target)
 
def __copy__ (self)
 
def hash (self)
 
- Public Member Functions inherited from Z3PPObject
def use_pp (self)
 

Additional Inherited Members

- Data Fields inherited from AstRef
 ast
 
 ctx
 

Detailed Description

Sequence expression.

Definition at line 9892 of file z3py.py.

Member Function Documentation

◆ __add__()

def __add__ (   self,
  other 
)

Definition at line 9898 of file z3py.py.

9898  def __add__(self, other):
9899  return Concat(self, other)
9900 
def Concat(args)
Definition: z3py.py:3785

◆ __getitem__()

def __getitem__ (   self,
  i 
)

Definition at line 9904 of file z3py.py.

9904  def __getitem__(self, i):
9905  if _is_int(i):
9906  i = IntVal(i, self.ctx)
9907  return SeqRef(Z3_mk_seq_at(self.ctx_ref(), self.as_ast(), i.as_ast()), self.ctx)
9908 
Z3_ast Z3_API Z3_mk_seq_at(Z3_context c, Z3_ast s, Z3_ast index)
Retrieve from s the unit sequence positioned at position index.
def IntVal(val, ctx=None)
Definition: z3py.py:2926

◆ __radd__()

def __radd__ (   self,
  other 
)

Definition at line 9901 of file z3py.py.

9901  def __radd__(self, other):
9902  return Concat(other, self)
9903 
def Concat(args)
Definition: z3py.py:3785

◆ as_string()

def as_string (   self)
Return a string representation of sequence expression.

Definition at line 9915 of file z3py.py.

9915  def as_string(self):
9916  """Return a string representation of sequence expression."""
9917  if self.is_string_value():
9918  return Z3_get_string(self.ctx_ref(), self.as_ast())
9919  return Z3_ast_to_string(self.ctx_ref(), self.as_ast())
9920 
9921 
Z3_string Z3_API Z3_ast_to_string(Z3_context c, Z3_ast a)
Convert the given AST node into a string.
Z3_string Z3_API Z3_get_string(Z3_context c, Z3_ast s)
Retrieve the string constant stored in s.

◆ is_string()

def is_string (   self)

Definition at line 9909 of file z3py.py.

9909  def is_string(self):
9910  return Z3_is_string_sort(self.ctx_ref(), Z3_get_sort(self.ctx_ref(), self.as_ast()))
9911 
def is_string(a)
Definition: z3py.py:9950
bool Z3_API Z3_is_string_sort(Z3_context c, Z3_sort s)
Check if s is a string sort.
Z3_sort Z3_API Z3_get_sort(Z3_context c, Z3_ast a)
Return the sort of an AST node.

◆ is_string_value()

def is_string_value (   self)

Definition at line 9912 of file z3py.py.

9912  def is_string_value(self):
9913  return Z3_is_string(self.ctx_ref(), self.as_ast())
9914 
def is_string_value(a)
Definition: z3py.py:9957
bool Z3_API Z3_is_string(Z3_context c, Z3_ast s)
Determine if s is a string constant.

◆ sort()

def sort (   self)

Definition at line 9895 of file z3py.py.

9895  def sort(self):
9896  return SeqSortRef(Z3_get_sort(self.ctx_ref(), self.as_ast()), self.ctx)
9897 
Z3_sort Z3_API Z3_get_sort(Z3_context c, Z3_ast a)
Return the sort of an AST node.