SIL.FieldWorks.IText.InterlinearExporter.AddStringAltMember C# (CSharp) Method

AddStringAltMember() public method

public AddStringAltMember ( int tag, int ws, IVwViewConstructor _vwvc ) : void
tag int
ws int
_vwvc IVwViewConstructor
return void
		public override void AddStringAltMember(int tag, int ws, IVwViewConstructor _vwvc)
		{
			//get the writing system for english for use in writing out the morphType, the types will ALWAYS be defined in english
			//but they may not be defined in other languages, using English on import and export should garauntee the correct behavior
			int englishWS = m_cache.WritingSystemFactory.GetWsFromStr("en");
			if (m_fDoingMorphType)
			{
				m_writer.WriteAttributeString("type", GetText(m_sda.get_MultiStringAlt(m_hvoCurr, tag, englishWS)));
				// also output the GUID so any tool that processes the output can know for sure which morphtype it is
				// Save the morphtype.  See LT-8288.
				m_guidMorphType = WriteGuidAttributeForCurrentObj();
			}
			else if (m_fDoingHeadword)
			{
				// Lexeme or citation form in headword. Dump it out, along with any saved affix marker.
				WritePrefixLangAlt(ws, tag);
				m_fAwaitingHeadwordForm = false;
			}
			else if (tag == MoFormTags.kflidForm)
			{
				if (m_fItemIsOpen)
				{
					WritePrefixLangAlt(ws, tag);
				}
			}
			else if (m_fItemIsOpen)
			{
				if (tag == LexSenseTags.kflidGloss)
					WriteLangAndContent(ws, GetMarkedGloss(m_hvoCurr, tag, ws));
				else
					WriteLangAndContent(ws, m_sda.get_MultiStringAlt(m_hvoCurr, tag, ws));
			}
			else if (tag == WfiWordformTags.kflidForm)
			{
				WriteItem(tag, "txt", ws);
			}
			else if (tag == WfiGlossTags.kflidForm)
			{
				WriteItem(tag, "gls", ws);
			}
			else if (tag == WfiMorphBundleTags.kflidForm)
			{
				WriteItem(tag, "txt", ws);
			}
			else if (tag == SegmentTags.kflidFreeTranslation ||
				tag == SegmentTags.kflidLiteralTranslation ||
				tag == NoteTags.kflidContent)
			{
				WriteItem(tag, m_sFreeAnnotationType, ws);
			}
			else if (tag == m_flidStTextTitle)
			{
				ITsString tssTitle = m_sda.get_MultiStringAlt(m_hvoCurr, tag, ws);
				if (!pendingTitles.Contains(tssTitle))
					pendingTitles.Add(tssTitle);
			}
			else if (tag == m_flidStTextSource)
			{
				ITsString source = m_sda.get_MultiStringAlt(m_hvoCurr, tag, ws);
				if (!pendingSources.Contains(source))
					pendingSources.Add(source);
			}
			else if (tag == CmMajorObjectTags.kflidDescription)
			{
				ITsString comment = m_sda.get_MultiStringAlt(m_hvoCurr, tag, ws);
				if (!pendingComments.Contains(comment))
					pendingComments.Add(comment);
			}
			else
			{
				Debug.WriteLine(
					String.Format("Export.AddStringAltMember(hvo={0}, tag={1}, ws={2})", m_hvoCurr, tag, ws));
			}
		}