X-Git-Url: https://gerrit.simantics.org/r/gitweb?a=blobdiff_plain;f=bundles%2Forg.simantics.databoard%2Fsrc%2Forg%2Fsimantics%2Fdataboard%2Faccessor%2FRecordAccessor.java;h=9c164cc16e0ab3724b447f8e9bff7fcf1e369436;hb=refs%2Fchanges%2F38%2F238%2F2;hp=712a1790ca656a76527c7b1612413a83a961b187;hpb=969bd23cab98a79ca9101af33334000879fb60c5;p=simantics%2Fplatform.git diff --git a/bundles/org.simantics.databoard/src/org/simantics/databoard/accessor/RecordAccessor.java b/bundles/org.simantics.databoard/src/org/simantics/databoard/accessor/RecordAccessor.java index 712a1790c..9c164cc16 100644 --- a/bundles/org.simantics.databoard/src/org/simantics/databoard/accessor/RecordAccessor.java +++ b/bundles/org.simantics.databoard/src/org/simantics/databoard/accessor/RecordAccessor.java @@ -1,20 +1,20 @@ -/******************************************************************************* - * Copyright (c) 2010 Association for Decentralized Information Management in - * Industry THTH ry. - * 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: - * VTT Technical Research Centre of Finland - initial API and implementation - *******************************************************************************/ +/******************************************************************************* + * Copyright (c) 2010 Association for Decentralized Information Management in + * Industry THTH ry. + * 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: + * VTT Technical Research Centre of Finland - initial API and implementation + *******************************************************************************/ package org.simantics.databoard.accessor; -import org.simantics.databoard.accessor.error.AccessorConstructionException; -import org.simantics.databoard.accessor.error.AccessorException; -import org.simantics.databoard.binding.Binding; -import org.simantics.databoard.type.RecordType; +import org.simantics.databoard.accessor.error.AccessorConstructionException; +import org.simantics.databoard.accessor.error.AccessorException; +import org.simantics.databoard.binding.Binding; +import org.simantics.databoard.type.RecordType; /** * Accessor to a Record. @@ -52,26 +52,26 @@ public interface RecordAccessor extends Accessor { T getFieldAccessor(String fieldName) throws AccessorConstructionException; /** - * Get field value. - * + * Get field value. + * * Note, use RecordAccessor#type().getComponentIndex( fieldName ) to get index.

* * @param index field index * @return the value of the field * @throws AccessorException */ - Object getFieldValue(int index, Binding fieldBinding) throws AccessorException; - - /** - * Get field value. - * - * Note, use RecordAccessor#type().getComponentIndex( fieldName ) to get index.

- * - * @param fieldName - * @return the value of the field - * @throws AccessorException - */ - Object getFieldValue(String fieldName, Binding fieldBinding) throws AccessorException; + Object getFieldValue(int index, Binding fieldBinding) throws AccessorException; + + /** + * Get field value. + * + * Note, use RecordAccessor#type().getComponentIndex( fieldName ) to get index.

+ * + * @param fieldName + * @return the value of the field + * @throws AccessorException + */ + Object getFieldValue(String fieldName, Binding fieldBinding) throws AccessorException; /** * Set field value. @@ -85,19 +85,19 @@ public interface RecordAccessor extends Accessor { * @throws AccessorException */ void setFieldValue(int index, Binding fieldBinding, Object value) throws AccessorException; - - /** - * Set field value. - * - * Writing the current value again may not emit an event. This is implementation - * specific.

- * - * @param fieldName - * @param fieldBinding - * @param value - * @throws AccessorException - */ - void setFieldValue(String fieldName, Binding fieldBinding, Object value) throws AccessorException; + + /** + * Set field value. + * + * Writing the current value again may not emit an event. This is implementation + * specific.

+ * + * @param fieldName + * @param fieldBinding + * @param value + * @throws AccessorException + */ + void setFieldValue(String fieldName, Binding fieldBinding, Object value) throws AccessorException; RecordType type();