We will now add in the code to test the new converter.
using System;
using Ant.ContentEntry;
using Ant.ContentEntry.Converters;
using Ant.ContentEntry.FieldDisplayers;
using Ant.ContentEntry.ClassInformation;
namespace HowTos
{
/// <summary>
/// Class used to check the converter
/// </summary>
[ClassOverview]
public class CheckConverter
{
int val;
/// <summary>
/// Gets and sets a test value
/// </summary>
[PropertyInformation(typeof(IntegerDivisibleConverter), typeof(InputEntry), true, 0)]
[PropertyLanguage("ENGLISH", "Val", "Test value", "*")]
public int Val {get {return val;} set {val = value;}}
}
}
This class defines a single field that has the converter of IntegerDivisibleConverter. This field is required and stores its value in an integer.