From d96caaa14e9e869e85eecc6b760221ad0579f68e Mon Sep 17 00:00:00 2001 From: Jeff Ames Date: Thu, 26 Jun 2008 20:20:30 +0000 Subject: Apply patch from bug #1606 -- Documentation for Data/Null, Data/Base. Thanks kerunix_Flan! --- OpenSim/Data/Base/BaseFieldMapper.cs | 46 ++++++++++++++++++++++++++++++++++++ 1 file changed, 46 insertions(+) (limited to 'OpenSim/Data/Base/BaseFieldMapper.cs') diff --git a/OpenSim/Data/Base/BaseFieldMapper.cs b/OpenSim/Data/Base/BaseFieldMapper.cs index 4fdc7b9..c7d6bc9 100644 --- a/OpenSim/Data/Base/BaseFieldMapper.cs +++ b/OpenSim/Data/Base/BaseFieldMapper.cs @@ -34,11 +34,17 @@ namespace OpenSim.Data.Base public delegate TField ObjectGetAccessor(TObj obj); public delegate void ObjectSetAccessor(TObj obj, TField value); + /// + /// + /// public abstract class BaseFieldMapper { private readonly BaseTableMapper m_tableMapper; private readonly string m_fieldName; + /// + /// + /// public string FieldName { get { return m_fieldName; } @@ -46,6 +52,9 @@ namespace OpenSim.Data.Base protected Type m_valueType; + /// + /// + /// public Type ValueType { get { return m_valueType; } @@ -53,6 +62,12 @@ namespace OpenSim.Data.Base public abstract object GetParamValue(object obj); + /// + /// + /// + /// + /// + /// public BaseFieldMapper(BaseTableMapper tableMapper, string fieldName, Type valueType) { m_fieldName = fieldName; @@ -62,6 +77,13 @@ namespace OpenSim.Data.Base public abstract void SetPropertyFromReader(object mapper, BaseDataReader reader); + /// + /// + /// + /// + /// + /// + /// public void RawAddParam(DbCommand command, List fieldNames, string fieldName, object value) { string paramName = m_tableMapper.CreateParamName(fieldName); @@ -74,6 +96,13 @@ namespace OpenSim.Data.Base command.Parameters.Add(param); } + /// + /// + /// + /// + /// + /// + /// public virtual void ExpandField(TObj obj, DbCommand command, List fieldNames) { string fieldName = FieldName; @@ -82,6 +111,11 @@ namespace OpenSim.Data.Base RawAddParam(command, fieldNames, fieldName, m_tableMapper.ConvertToDbType(value)); } + /// + /// + /// + /// + /// protected virtual object GetValue(BaseDataReader reader) { object value; @@ -130,6 +164,11 @@ namespace OpenSim.Data.Base } } + /// + /// + /// + /// + /// public class ObjectField : BaseFieldMapper { private readonly ObjectGetAccessor m_fieldGetAccessor; @@ -157,6 +196,13 @@ namespace OpenSim.Data.Base } + /// + /// + /// + /// + /// + /// + /// public ObjectField(BaseTableMapper tableMapper, string fieldName, ObjectGetAccessor rowMapperGetAccessor, ObjectSetAccessor rowMapperSetAccessor) : base(tableMapper, fieldName, typeof(TField)) -- cgit v1.1