These classes are command objects representing the task of getting a string value from a browse column in a way specified by its node and writing a new string value back to the object. This is orthogonal to the several different transformations that can be performed on the strings so obtained. This abstract class also has the responsibility for deciding whether a field read/writer can be created for the column, and if so, for creating the appropriate subclass.
Inheritance: IGhostable
Example #1
0
		private string m_name; // string to show in menu

		public FieldComboItem(string name, int icol, FieldReadWriter accessor)
		{
			m_name = name;
			ColumnIndex = icol;
			Accessor = accessor;
		}
Example #2
0
		public ReplaceWithMethod(FdoCache cache, ISilDataAccessManaged sda, FieldReadWriter accessor, XmlNode spec, IVwPattern pattern, ITsString replacement)
			: base(cache, sda, accessor, spec)
		{
			m_pattern = pattern;
			m_replacement = replacement;
			m_pattern.ReplaceWith = m_replacement;
			m_textSourceInit = VwStringTextSourceClass.Create();
			m_ts = m_textSourceInit as IVwTextSource;
		}
Example #3
0
		public ClearMethod(FdoCache cache, ISilDataAccessManaged sda, FieldReadWriter accessor, XmlNode spec)
			: base(cache, sda, accessor, spec)
		{
			ITsStrFactory tsf = TsStrFactoryClass.Create();
			m_newValue = tsf.MakeString("", accessor.WritingSystem);
		}
Example #4
0
		public TransduceMethod(FdoCache cache, ISilDataAccessManaged sda, FieldReadWriter dstAccessor, XmlNode spec, FieldReadWriter srcAccessor,
			ECInterfaces.IEncConverter converter, ITsString tssSep, NonEmptyTargetOptions options)
			: base(cache, sda, dstAccessor, spec)
		{
			m_srcAccessor = srcAccessor;
			m_converter = converter;
			m_tssSep = tssSep;
			m_options = options;
		}
Example #5
0
		public BulkCopyMethod(FdoCache cache, ISilDataAccessManaged sda, FieldReadWriter dstAccessor,
			XmlNode spec, FieldReadWriter srcAccessor, ITsString tssSep, NonEmptyTargetOptions options)
			: base(cache, sda, dstAccessor, spec)
		{
			m_srcAccessor = srcAccessor;
			m_tssSep = tssSep;
			m_options = options;
		}
Example #6
0
		public DoItMethod(FdoCache cache, ISilDataAccessManaged sda, FieldReadWriter accessor, XmlNode spec)
		{
			m_cache = cache;
			m_accessor = accessor;
			m_sda = sda;
			m_nodeSpec = spec;

			m_sEditIf = XmlUtils.GetOptionalAttributeValue(spec, "editif");
			if (!String.IsNullOrEmpty(m_sEditIf))
			{
				if (m_sEditIf[0] == '!')
				{
					m_fEditIfNot = true;
					m_sEditIf = m_sEditIf.Substring(1);
				}
				string sWs = StringServices.GetWsSpecWithoutPrefix(spec);
				if (sWs != null)
					m_wsEditIf = XmlViewsUtils.GetWsFromString(sWs, m_cache);
			}
		}
Example #7
0
		FieldReadWriter m_accessor; // thing that can read/write strings.

		public FieldComboItem(string name, int icol, FieldReadWriter accessor)
		{
			m_name = name;
			m_icol = icol;
			m_accessor = accessor;
		}
Example #8
0
		public DoItMethod(FdoCache cache, FieldReadWriter accessor, XmlNode spec)
		{
			m_cache = cache;
			m_accessor = accessor;
			m_sda = cache.MainCacheAccessor;
			m_cda = cache.VwCacheDaAccessor;
			m_nodeSpec = spec;

			m_sEditIf = XmlUtils.GetOptionalAttributeValue(spec, "editif");
			if (!String.IsNullOrEmpty(m_sEditIf))
			{
				if (m_sEditIf[0] == '!')
				{
					m_fEditIfNot = true;
					m_sEditIf = m_sEditIf.Substring(1);
				}
				string sWs = XmlUtils.GetOptionalAttributeValue(spec, "ws");
				if (sWs != null)
				{
					if (sWs.StartsWith(LangProject.WsParamLabel))
						sWs = sWs.Substring(LangProject.WsParamLabel.Length);
					m_wsEditIf = XmlViewsUtils.GetWsFromString(sWs, m_cache);
				}
			}
		}