mirror of
				https://github.com/Z3Prover/z3
				synced 2025-10-31 03:32:28 +00:00 
			
		
		
		
	add string accessors to managed APIs #1051
Signed-off-by: Nikolaj Bjorner <nbjorner@microsoft.com>
This commit is contained in:
		
							parent
							
								
									546d22e77a
								
							
						
					
					
						commit
						52e0f3b539
					
				
					 4 changed files with 50 additions and 36 deletions
				
			
		|  | @ -1277,6 +1277,26 @@ public class Expr extends AST | |||
|         return isApp() && getFuncDecl().getDeclKind() == Z3_decl_kind.Z3_OP_LABEL_LIT; | ||||
|     } | ||||
| 
 | ||||
|     /** | ||||
|      * Check whether expression is a string constant. | ||||
|      * @return a boolean | ||||
|      */ | ||||
|     public boolean isString()  | ||||
|     { | ||||
|         return isApp() && Native.isString(getContext().nCtx(), getNativeObject()); | ||||
|     } | ||||
| 
 | ||||
|     /** | ||||
|      * Retrieve string corresponding to string constant. | ||||
|      * Remark: the expression should be a string constant, (isString() should return true). | ||||
|      * @throws Z3Exception on error | ||||
|      * @return a string | ||||
|      */ | ||||
|     public String getString() | ||||
|     { | ||||
| 	return Native.getString(getContext().nCtx(), getNativeObject()); | ||||
|     } | ||||
| 
 | ||||
|     /** | ||||
|      * Indicates whether the term is a binary equivalence modulo namings. | ||||
|      * Remarks: This binary predicate is used in proof terms. It captures | ||||
|  |  | |||
		Loading…
	
	Add table
		Add a link
		
	
		Reference in a new issue