private void BindPrimitiveArraySecondPass(HbmPrimitiveArray primitiveArrayMapping, List model,
			IDictionary<string, PersistentClass> persistentClasses, IDictionary<string, MetaAttribute> inheritedMetas)
		{
			BindCollectionSecondPass(primitiveArrayMapping, model, persistentClasses, inheritedMetas);

			// Index
			BindCollectionIndex(primitiveArrayMapping, model);
			if (primitiveArrayMapping.ListIndex != null && !string.IsNullOrEmpty(primitiveArrayMapping.ListIndex.@base))
			{
				model.BaseIndex = Convert.ToInt32(primitiveArrayMapping.ListIndex.@base);
			}
		}
		private void BindPrimitiveArray(HbmPrimitiveArray arrayMapping, PrimitiveArray model, string prefix, string path, System.Type containingType, IDictionary<string, MetaAttribute> inheritedMetas)
		{
			BindCollection(arrayMapping, model, prefix, path, containingType, inheritedMetas);

			var element = arrayMapping.ElementRelationship as HbmElement;
			if (element != null)
			{
				string typeName;
				var typeAttribute = element.Type;
				if (typeAttribute != null)
					typeName = typeAttribute.name;
				else
					throw new MappingException("type for <element> was not defined");
				IType type = TypeFactory.HeuristicType(typeName, null);
				if (type == null)
					throw new MappingException("could not interpret type: " + typeName);

				model.ElementClassName = type.ReturnedClass.AssemblyQualifiedName;
			}
		}
		private void AddPrimitiveArraySecondPass(HbmPrimitiveArray primitiveArrayMapping, Array model, IDictionary<string, MetaAttribute> inheritedMetas)
		{
			mappings.AddSecondPass(delegate(IDictionary<string, PersistentClass> persistentClasses)
			{
				PreCollectionSecondPass(model);
				BindPrimitiveArraySecondPass(primitiveArrayMapping, model, persistentClasses, inheritedMetas);
				PostCollectionSecondPass(model);
			});
		}
		private Mapping.Collection CreatePrimitiveArray(HbmPrimitiveArray primitiveArrayMapping, string prefix, string path,
			PersistentClass owner, System.Type containingType, IDictionary<string, MetaAttribute> inheritedMetas)
		{
			var array = new PrimitiveArray(owner);
			BindPrimitiveArray(primitiveArrayMapping, array, prefix, path, containingType,inheritedMetas);
			AddPrimitiveArraySecondPass(primitiveArrayMapping, array, inheritedMetas);
			return array;
		}