Skip to content

Instantly share code, notes, and snippets.


Meinte Boersma dslmeinte

View GitHub Profile
dslmeinte / projection-essence.ts
Last active July 17, 2017 18:51
Projection of a directed graph (pseudo-TS-code)
View projection-essence.ts
export enum Style {
none, selected, highlighted
export abstract class Element {
abstract style(): Style;
export class ProjectedVertex extends Element {
id: number;
dslmeinte / model-essence.ts
Last active July 17, 2017 18:47
Model of a directed graph (pseudo-TS-code)
View model-essence.ts
export class Point { x: number; y: number; }
export class Vertex { id: number; position: Point; toIds: number[]; }
export class Model { vertices: Vertex[]; }
dslmeinte / DomainModelExtensions.xtend
Created November 23, 2011 14:16
extensions for model elements of the enhanced DomainModel example (Xtext 1.0)
View DomainModelExtensions.xtend
import nl.dslmeinte.xtext.examples.domainmodel.domainModel.Entity
import nl.dslmeinte.xtext.examples.domainmodel.domainModel.Reference
import nl.dslmeinte.xtext.examples.domainmodel.domainModel.Attribute
import nl.dslmeinte.xtext.examples.domainmodel.domainModel.StructuralFeature
* Extensions for model elements of a domain model.
* Usage in Xtend files:
dslmeinte / DomainModel.xtext
Created November 23, 2011 14:13
grammar for Xtext 1.0's DomainModel example, enhanced with "path expressions"
View DomainModel.xtext
* Grammar taken from the Xtext 1.0.x Domainmodel example
* and enhanced with path expressions: see .
grammar nl.dslmeinte.xtext.examples.domainmodel.DomainModel with org.eclipse.xtext.common.Terminals
generate domainModel ""