001package org.andromda.core.translation; 002 003/** 004 * Provides expression translation capabilities. Every expression translator must implement this interface. 005 * 006 * @author Chad Brandon 007 */ 008public interface Translator 009{ 010 /** 011 * Translates the expression into a translated Expression instance. 012 * 013 * @param translationLibrary the library and translation to lookup perform the translation (i.e. sql.Oracle9i: 014 * library to use would be "sql" and translation from the sql library would be 015 * 'Oracle9i'). 016 * @param contextElement the optional element in the model to which the expression applies (the context element 017 * of an OCL expression for example). 018 * @param expression the expression (OCL, etc) to translate. 019 * @return Expression the expression containing the translated result. 020 * @see org.andromda.core.translation.Expression 021 */ 022 public Expression translate( 023 String translationLibrary, 024 String expression, 025 Object contextElement); 026}