Questions tagged [xbase]

(A) Xbase is a structured format for storing data in files and indexes. It was used originally by foxPro and dBase. (B) Xbase is an expression language provided by Xtext.

83 questions
0
votes
1 answer

Convert Variable to decimal XBASE

Have a variable containing a value like '000000017733'. - Need to convert it to '000000177,33' - Then make a sum with other variable. - Then convert it again to a string that will look like (for example) '000000008921' XBASE any one can…
Rui Pires
  • 1
  • 3
0
votes
1 answer

How to generate Java code for Xbase XExpression using JvmModelInferrer?

I am trying to do the simplest example I can think of to use Xbase and the JvmModelInferrer, rather than writing a code generator. I've cut down the JVM language tutorial but I can't get correct Java code from an XExpression (or XBlockExpression).…
guraaku
  • 205
  • 1
  • 7
0
votes
0 answers

What do those initial 3 bytes mean, in the response read after the Open method of the TIPClientHttp class?

When I call the Read method, right after an Open of the TIPClientHttp class, I get a JSON string from a PHP page. However, I noticed that three bytes of strange characters that precede the desired data occur, along. This happens with one URL and…
0
votes
0 answers

No completion for Xbase expressions when embedded in another Xtext DSL

I am building a Xtext DSL and I want to embed Xbase expressions in some specific places to interpret part of my models using the Xbase interpreter, but I am not able to have method completion in the generated editor. I reused the examples provided…
zelus
  • 143
  • 8
0
votes
1 answer

How to add a new field / column to an existing xBase file / table

I'm working on a legacy desktop application. It was written using Xbase++ from Alaska software. I'm just trying to add a new field to an existing db file but I can't find any documentation about how to do it. I have looked at…
0
votes
0 answers

Call method dynamically based on variable name

I currently have a generated XBase object with some method names: get_0(), get_1(), get_...(), get_50() Now I'd like to call them with a loop instead of 50 lines, like this for(var i = 0; i <= 50; i++) { fiftyGetters.get_ + i // } How can I…
Ivar Reukers
  • 7,560
  • 9
  • 56
  • 99
0
votes
0 answers

Referencing a containing class from an inner class with Xtext, Xbase and the JvmModelInferrer

I am having a problem with referencing the container class from an inner class with Xtext, Xbase and the Java model inferrer. To highlight my problem, let me first demonstrate a working example (derived from Implementing Domain-Specific Languages…
fundagain
  • 398
  • 1
  • 6
  • 23
0
votes
1 answer

How to JvmModelInferrer method body from XExpression and append boilerplate code

In a JvmModelInferrer, when constructing the body of a method or constructor, how do you insert both an XExpression from the grammar body = op.body and additional "boilerplate" code, for example body = [ append( ''' …
fundagain
  • 398
  • 1
  • 6
  • 23
0
votes
1 answer

Extending the Xbase type system

I have this simple DSL, inspired from the mini-java example but based on XBase. See below to take a quick look at my grammar. Package returns Package: {Package} 'package' name = QualifiedName (importSection = XImportSection)? (classifiers +=…
Amine Ben
  • 65
  • 6
0
votes
1 answer

Execution of extended Xbase interpreter leads to runtime exception

I am currently writing an interpreter for an Xtext language that extends Xbase. To do so I am inheriting from XbaseInterpreter, adding my own run method and override the dispatch method doEvaluateProgram with my new abstract concepts. The problem…
Manuel Leduc
  • 1,849
  • 3
  • 23
  • 39
0
votes
0 answers

XCORE meets XTEXT

I have started creating the DSL using XTEXT and it is working really good. Today I found XCORE as another modeling approach that can be combined with XTEXT also. Can someone please explain what would be the use case of creating DSL with those two…
0
votes
0 answers

Xtext Cannot resolve reference - MongoDb example

I have just started learning XTEXT, and I can see the bright future of automatic coding with it. :) Currently I am working on seven-languages training part and I am stucked on MongoDb example. I am following the description of that example but I am…
0
votes
1 answer

how to create expression in xbase++

String GSTINFORMAT_REGEX = "[0-9]{2}[a-zA-Z]{5}[0-9]{4}[a-zA-Z]{1}[1-9A-Za-z]{1}[Z]{1}[0-9a-zA-Z]{1}"; I want to create this expression in xbase++. Please tell me how to create this kind of expression. Thanks in advance.
0
votes
1 answer

Xtext: Use EClass in XExpression

I am writing on a Xtext grammar that uses XExpressions and also operates on Eclasses. Now I want to also be able to access Eclasses from the XExpression, for example I write an expression like this: Eclass1.attribute1 = Eclass2.attribute1 I would…
user2444765
0
votes
1 answer

Referring to generated types in Xtext/Xbase grammar

I am working on an Xtext grammar using Xbase. The grammar permits the user to create a set of Java classes with supertypes from one DSL file. I therefore created a rule like the following: javaClass: name=ID ':'…
Thomas
  • 3
  • 2