blob: 5d65d87cfec6e232bf89d116334d51567d4e5a39 [file] [log] [blame]
/**
*
* Copyright (c) 2011, 2016 - Loetz GmbH&Co.KG (69115 Heidelberg, Germany)
*
* All rights reserved. This program and the accompanying materials
* are made available under the terms of the Eclipse Public License v1.0
* which accompanies this distribution, and is available at
* http://www.eclipse.org/legal/epl-v10.html
*
* Contributors:
* Christophe Loetz (Loetz GmbH&Co.KG) - initial implementation
*
*/
@xcore.lang.GenModel(fileExtensions="message")
@GenModel(modelName="MessageDSL")
@GenModel(prefix="MessageDSL")
@GenModel(updateClasspath="false")
@GenModel(copyrightText="Copyright (c) 2011, 2016 - Loetz GmbH&Co.KG (69115 Heidelberg, Germany)
All rights reserved. This program and the accompanying materials
are made available under the terms of the Eclipse Public License v1.0
which accompanies this distribution, and is available at
http://www.eclipse.org/legal/epl-v10.html
Based on ideas from Xtext, Xtend, Xcore
Contributors:
Christophe Loetz (Loetz GmbH&Co.KG) - Initial implementation
")
@Ecore(nsURI="http://osbp.eclipse.org/xtext/messagedsl/MessageDSL")
@Ecore(nsPrefix="messageDSL")
@Ecore(rootPackage="messageDSL")
package org.eclipse.osbp.xtext.messagedsl
import org.eclipse.osbp.dsl.semantic.common.types.LPackage
class MessageModel {
contains MessagePackage pckg
}
class MessagePackage extends LPackage {
contains MessageCategory[] categories
}
class MessageCategory {
String name
contains MessageGroup[] groups
}
class MessageGroup {
String name
contains MessageItem[] items
}
class MessageItem {
String name
contains MessageParameter[] parameters
AutomaticOutputEnum[] automaticOutputs
contains MessageDefaultFormat allFormat
contains MessageDefaultFormat logFormat
contains MessageDefaultFormat showFormat
}
class MessageParameter {
String name
ParameterTypeEnum oftype
}
enum ParameterTypeEnum {
BOOLEAN as 'boolean'
INTEGER as 'int'
DOUBLE as 'double'
STRING as 'String'
CLASS as 'Class'
OBJECT as 'Object'
EXCEPTION as 'Exception'
}
enum AutomaticOutputEnum {
LOG_TRACE as 'log-trace'
LOG_DEBUG as 'log-debug'
LOG_INFO as 'log-info'
LOG_WARN as 'log-warn'
LOG_ERROR as 'log-error'
SHOW_INFO as 'show-info'
SHOW_WARN as 'show-warn'
SHOW_ERROR as 'show-error'
}
class MessageDefaultFormat {
String format
}