1 /*******************************************************************************
\r
2 * Copyright (c) 2010 Association for Decentralized Information Management in
\r
4 * All rights reserved. This program and the accompanying materials
\r
5 * are made available under the terms of the Eclipse Public License v1.0
\r
6 * which accompanies this distribution, and is available at
\r
7 * http://www.eclipse.org/legal/epl-v10.html
\r
10 * VTT Technical Research Centre of Finland - initial API and implementation
\r
11 *******************************************************************************/
\r
12 package org.simantics.databoard.binding.factory;
14 import org.simantics.databoard.binding.Binding;
\r
15 import org.simantics.databoard.binding.error.BindingConstructionException;
\r
16 import org.simantics.databoard.binding.error.RuntimeBindingConstructionException;
\r
17 import org.simantics.databoard.type.Datatype;
\r
19 public interface BindingScheme {
22 * Get binding of a data type
24 * @param type data type
26 * @throws BindingConstructionException if data type is not supported
28 Binding getBinding(Datatype type) throws BindingConstructionException;
31 * Get binding of a data type
\r
33 * @param type data type
\r
35 * @throws RuntimeBindingConstructionException if data type is not supported
\r
37 Binding getBindingUnchecked(Datatype type) throws RuntimeBindingConstructionException;
\r
40 * Tests if the scheme supports a type
43 * @return true if the type is supported by the scheme
45 boolean supportsType(Datatype type);