/// <inheritdoc/> public string ToDelimitedString() { CultureInfo culture = CultureInfo.CurrentCulture; return(string.Format( culture, StringHelper.StringFormatSequence(0, 16, Configuration.FieldSeparator), Id, ManufacturerDistributor != null ? string.Join(Configuration.FieldRepeatSeparator, ManufacturerDistributor.Select(x => x.ToDelimitedString())) : null, Country?.ToDelimitedString(), BrandName, DeviceFamilyName, GenericName?.ToDelimitedString(), ModelIdentifier != null ? string.Join(Configuration.FieldRepeatSeparator, ModelIdentifier) : null, CatalogueIdentifier, OtherIdentifier != null ? string.Join(Configuration.FieldRepeatSeparator, OtherIdentifier) : null, ProductCode?.ToDelimitedString(), MarketingBasis, MarketingApprovalId, LabeledShelfLife?.ToDelimitedString(), ExpectedShelfLife?.ToDelimitedString(), DateFirstMarketed.HasValue ? DateFirstMarketed.Value.ToString(Consts.DateTimeFormatPrecisionSecond, culture) : null, DateLastMarketed.HasValue ? DateLastMarketed.Value.ToString(Consts.DateTimeFormatPrecisionSecond, culture) : null ).TrimEnd(Configuration.FieldSeparator.ToCharArray())); }
private Name ParseName() { Name signature = null; while (true) { switch (CurrentToken.Kind) { case TokenKind.Identifier: break; case TokenKind.Keyword: if (signature == null) { throw InvalidSignature(); } break; default: throw InvalidSignature(); } var name = EatToken().Text; signature = new QualifiedName(signature, name); if (IsStartOfTypeArguments()) { var typeParameters = ParseTypeParameters(); signature = new GenericName((QualifiedName)signature, typeParameters); } if (CurrentToken.Kind != TokenKind.Dot) { return(signature); } EatToken(); } }
private bool loadBaseEntries(Chilkat.Log log) { // Do not add base entries for CkString or CkByteData. if (GenericName.Equals("CkString") || GenericName.Equals("CkByteData")) { return(true); } Chilkat.Xml xmlBase = new Chilkat.Xml(); //string baseXmlPath = NoBaseEntries ? GenBase.m_baseUtf8XmlPath : GenBase.m_baseEntriesXmlPath; string strBaseEntriesXml = ""; if (NoBaseEntries) { strBaseEntriesXml = AppData.GetAppData("appData/apiManager/basePropUtf8.xml"); } else { strBaseEntriesXml = AppData.GetAppData("appData/apiManager/baseEntries.xml"); } if (!xmlBase.LoadXml(strBaseEntriesXml)) //if (!xmlBase.LoadXmlFile(baseXmlPath)) { log.LogError("Failed to load baseEntries.xml"); return(false); } // No longer need this.. //xmlBase.AddOrUpdateAttribute("sourceXmlPath", baseXmlPath); addClassEntries(xmlBase); return(true); }
public bool Unmap() { StopPlayingDisc(); foreach (TrackInfo track in DiscModel) { track.CanPlay = false; } OnUpdated(); SourceMessage eject_message = new SourceMessage(this); eject_message.FreezeNotify(); eject_message.IsSpinning = true; eject_message.CanClose = false; // Translators: {0} is the type of disc, "Audio CD" or "DVD" eject_message.Text = String.Format(Catalog.GetString("Ejecting {0}..."), GenericName.ToLower()); eject_message.ThawNotify(); PushMessage(eject_message); ThreadPool.QueueUserWorkItem(delegate { try { DiscModel.Volume.Unmount(); DiscModel.Volume.Eject(); ThreadAssist.ProxyToMain(delegate { Service.UnmapDiscVolume(DiscModel.Volume.Uuid); Dispose(); }); } catch (Exception e) { ThreadAssist.ProxyToMain(delegate { ClearMessages(); eject_message.IsSpinning = false; eject_message.SetIconName("dialog-error"); // Translators: {0} is the type of disc, "Audio CD" or "DVD". {1} is the error message. eject_message.Text = String.Format(Catalog.GetString("Could not eject {0}: {1}"), GenericName.ToLower(), e.Message); PushMessage(eject_message); foreach (TrackInfo track in Model) { track.CanPlay = true; } OnUpdated(); }); Log.Exception(e); } }); return(true); }
public void Return_False_On_IsIdentical_When_Identity_Is_Different() { var x = new GenericName { GnGnK = 1 }; var y = new GenericName { GnGnK = 2 }; Assert.IsFalse(x.IsIdentical(y)); }
public void Validate() { Name.ValidateRequired("Name"); GenericName.ValidateOptional("GenericName"); Dose.ValidateOptional("Dose"); Strength.ValidateOptional("Strength"); Frequency.ValidateOptional("Frequency"); Route.ValidateOptional("Route"); Indication.ValidateOptional("Indication"); StartDate.ValidateOptional("StartDate"); StopDate.ValidateOptional("StopDate"); Prescribed.ValidateOptional("Prescribed"); Prescription.ValidateOptional("Prescription"); }
public void Copy_All_Fields_From_One_To_Another() { var from = new GenericName { GnGnAm = "A", GnGnK = 3, MutKod = MutKod.RecordUpdated, }; var to = new GenericName(); from.CopyTo(to); Assert.IsTrue(new GenericNameComparer().Equals(from, to)); }
private bool loadBaseEntries(Chilkat.Log log) { // Do not add base entries for CkString or CkByteData. if (GenericName.Equals("CkString") || GenericName.Equals("CkByteData")) { return(true); } Chilkat.Xml xmlBase = new Chilkat.Xml(); string baseXmlPath = NoBaseEntries ? GenBase.m_baseUtf8XmlPath : GenBase.m_baseEntriesXmlPath; if (!xmlBase.LoadXmlFile(baseXmlPath)) { log.LogError("Failed to load baseEntries.xml"); return(false); } xmlBase.AddOrUpdateAttribute("sourceXmlPath", baseXmlPath); addClassEntries(xmlBase); return(true); }
public void Be_Able_To_Parse_A_Given_Line_To_A_GenericName_Model() { var expected = new GenericName { GnGnAm = "COMBINATIE PREPARAAT", GnGnK = 00019, MutKod = MutKod.RecordNotChanged }; const string data = @"07500000019COMBINATIE PREPARAAT 000019000019SW000000000000000 000000000000 0000000000000000000XX 000000000000000000000000000000"; byte[] dataBytes = Encoding.UTF8.GetBytes(data); var memoryStream = new MemoryStream(dataBytes); var serializer = new GStandardFileSerializer<GenericName>(); var lines = serializer.ReadLines(memoryStream); var model = lines.FirstOrDefault(); Assert.IsNotNull(model); Assert.AreEqual(expected.GnGnAm, model.GnGnAm); Assert.AreEqual(expected.GnGnK, model.GnGnK); Assert.AreEqual(expected.MutKod, model.MutKod); }
private Name ParseName() { Name signature = null; while (true) { if (CurrentToken.Kind != TokenKind.Identifier) { throw InvalidSignature(); } var name = EatToken().Text; signature = new QualifiedName(signature, name); if (CurrentToken.Kind == TokenKind.LessThan) { var typeParameters = ParseTypeParameters(); signature = new GenericName((QualifiedName)signature, typeParameters); } if (CurrentToken.Kind != TokenKind.Dot) { return(signature); } EatToken(); } }
/// <summary> /// Gets a string representation of the medication. /// </summary> /// /// <returns> /// A string representation of the medication. /// </returns> /// public override string ToString() { StringBuilder result = new StringBuilder(200); result.Append(Name); if (GenericName != null) { result.Append(" "); result.AppendFormat( Resources.MedicationToStringFormatGenericName, GenericName.ToString()); } if (Strength != null) { result.AppendFormat( Resources.ListFormat, Strength.ToString()); } if (Dose != null) { result.AppendFormat( Resources.ListFormat, Dose.ToString()); } if (Frequency != null) { result.Append(" "); result.Append(Frequency); } return(result.ToString()); }
public bool Equals(MethodTypeParams other) => GenericName.Equals(other.GenericName) && ConstrainedKind.Equals(other.ConstrainedKind) && ConstrainedTypes.SequenceEqual(other.ConstrainedTypes);
public void Return_True_On_IsIdentical_When_Identity_Is_Equal() { var x = new GenericName { GnGnK = 1 }; var y = new GenericName { GnGnK = 1 }; Assert.IsTrue(x.IsIdentical(y)); }
public static Doc Print(SyntaxNode syntaxNode) { if (syntaxNode == null) { return(Doc.Null); } // TODO 0 kill? runtime repo has files that will fail on deep recursion if (depth > 200) { throw new InTooDeepException(); } depth++; try { switch (syntaxNode) { case AliasQualifiedNameSyntax aliasQualifiedNameSyntax: return(AliasQualifiedName.Print(aliasQualifiedNameSyntax)); case AnonymousMethodExpressionSyntax anonymousMethodExpressionSyntax: return(AnonymousMethodExpression.Print(anonymousMethodExpressionSyntax)); case AnonymousObjectCreationExpressionSyntax anonymousObjectCreationExpressionSyntax: return(AnonymousObjectCreationExpression.Print( anonymousObjectCreationExpressionSyntax )); case AnonymousObjectMemberDeclaratorSyntax anonymousObjectMemberDeclaratorSyntax: return(AnonymousObjectMemberDeclarator.Print( anonymousObjectMemberDeclaratorSyntax )); case ArgumentListSyntax argumentListSyntax: return(ArgumentList.Print(argumentListSyntax)); case ArgumentSyntax argumentSyntax: return(Argument.Print(argumentSyntax)); case ArrayCreationExpressionSyntax arrayCreationExpressionSyntax: return(ArrayCreationExpression.Print(arrayCreationExpressionSyntax)); case ArrayRankSpecifierSyntax arrayRankSpecifierSyntax: return(ArrayRankSpecifier.Print(arrayRankSpecifierSyntax)); case ArrayTypeSyntax arrayTypeSyntax: return(ArrayType.Print(arrayTypeSyntax)); case ArrowExpressionClauseSyntax arrowExpressionClauseSyntax: return(ArrowExpressionClause.Print(arrowExpressionClauseSyntax)); case AssignmentExpressionSyntax assignmentExpressionSyntax: return(AssignmentExpression.Print(assignmentExpressionSyntax)); case AttributeListSyntax attributeListSyntax: return(AttributeList.Print(attributeListSyntax)); case AwaitExpressionSyntax awaitExpressionSyntax: return(AwaitExpression.Print(awaitExpressionSyntax)); case BaseExpressionSyntax baseExpressionSyntax: return(BaseExpression.Print(baseExpressionSyntax)); case BaseFieldDeclarationSyntax baseFieldDeclarationSyntax: return(BaseFieldDeclaration.Print(baseFieldDeclarationSyntax)); case BaseListSyntax baseListSyntax: return(BaseList.Print(baseListSyntax)); case BaseMethodDeclarationSyntax baseMethodDeclarationSyntax: return(BaseMethodDeclaration.Print(baseMethodDeclarationSyntax)); case BasePropertyDeclarationSyntax basePropertyDeclarationSyntax: return(BasePropertyDeclaration.Print(basePropertyDeclarationSyntax)); case BaseTypeDeclarationSyntax baseTypeDeclarationSyntax: return(BaseTypeDeclaration.Print(baseTypeDeclarationSyntax)); case BinaryExpressionSyntax binaryExpressionSyntax: return(BinaryExpression.Print(binaryExpressionSyntax)); case BinaryPatternSyntax binaryPatternSyntax: return(BinaryPattern.Print(binaryPatternSyntax)); case BlockSyntax blockSyntax: return(Block.Print(blockSyntax)); case BracketedArgumentListSyntax bracketedArgumentListSyntax: return(BracketedArgumentList.Print(bracketedArgumentListSyntax)); case BracketedParameterListSyntax bracketedParameterListSyntax: return(BracketedParameterList.Print(bracketedParameterListSyntax)); case BreakStatementSyntax breakStatementSyntax: return(BreakStatement.Print(breakStatementSyntax)); case CasePatternSwitchLabelSyntax casePatternSwitchLabelSyntax: return(CasePatternSwitchLabel.Print(casePatternSwitchLabelSyntax)); case CaseSwitchLabelSyntax caseSwitchLabelSyntax: return(CaseSwitchLabel.Print(caseSwitchLabelSyntax)); case CastExpressionSyntax castExpressionSyntax: return(CastExpression.Print(castExpressionSyntax)); case CatchClauseSyntax catchClauseSyntax: return(CatchClause.Print(catchClauseSyntax)); case CheckedExpressionSyntax checkedExpressionSyntax: return(CheckedExpression.Print(checkedExpressionSyntax)); case CheckedStatementSyntax checkedStatementSyntax: return(CheckedStatement.Print(checkedStatementSyntax)); case ClassOrStructConstraintSyntax classOrStructConstraintSyntax: return(ClassOrStructConstraint.Print(classOrStructConstraintSyntax)); case CompilationUnitSyntax compilationUnitSyntax: return(CompilationUnit.Print(compilationUnitSyntax)); case ConditionalAccessExpressionSyntax conditionalAccessExpressionSyntax: return(ConditionalAccessExpression.Print(conditionalAccessExpressionSyntax)); case ConditionalExpressionSyntax conditionalExpressionSyntax: return(ConditionalExpression.Print(conditionalExpressionSyntax)); case ConstantPatternSyntax constantPatternSyntax: return(ConstantPattern.Print(constantPatternSyntax)); case ConstructorConstraintSyntax constructorConstraintSyntax: return(ConstructorConstraint.Print(constructorConstraintSyntax)); case ConstructorInitializerSyntax constructorInitializerSyntax: return(ConstructorInitializer.Print(constructorInitializerSyntax)); case ContinueStatementSyntax continueStatementSyntax: return(ContinueStatement.Print(continueStatementSyntax)); case DeclarationExpressionSyntax declarationExpressionSyntax: return(DeclarationExpression.Print(declarationExpressionSyntax)); case DeclarationPatternSyntax declarationPatternSyntax: return(DeclarationPattern.Print(declarationPatternSyntax)); case DefaultConstraintSyntax defaultConstraintSyntax: return(DefaultConstraint.Print(defaultConstraintSyntax)); case DefaultExpressionSyntax defaultExpressionSyntax: return(DefaultExpression.Print(defaultExpressionSyntax)); case DefaultSwitchLabelSyntax defaultSwitchLabelSyntax: return(DefaultSwitchLabel.Print(defaultSwitchLabelSyntax)); case DelegateDeclarationSyntax delegateDeclarationSyntax: return(DelegateDeclaration.Print(delegateDeclarationSyntax)); case DiscardDesignationSyntax discardDesignationSyntax: return(DiscardDesignation.Print(discardDesignationSyntax)); case DiscardPatternSyntax discardPatternSyntax: return(DiscardPattern.Print(discardPatternSyntax)); case DoStatementSyntax doStatementSyntax: return(DoStatement.Print(doStatementSyntax)); case ElementAccessExpressionSyntax elementAccessExpressionSyntax: return(ElementAccessExpression.Print(elementAccessExpressionSyntax)); case ElementBindingExpressionSyntax elementBindingExpressionSyntax: return(ElementBindingExpression.Print(elementBindingExpressionSyntax)); case ElseClauseSyntax elseClauseSyntax: return(ElseClause.Print(elseClauseSyntax)); case EmptyStatementSyntax emptyStatementSyntax: return(EmptyStatement.Print(emptyStatementSyntax)); case EnumMemberDeclarationSyntax enumMemberDeclarationSyntax: return(EnumMemberDeclaration.Print(enumMemberDeclarationSyntax)); case EqualsValueClauseSyntax equalsValueClauseSyntax: return(EqualsValueClause.Print(equalsValueClauseSyntax)); case ExpressionStatementSyntax expressionStatementSyntax: return(ExpressionStatement.Print(expressionStatementSyntax)); case ExternAliasDirectiveSyntax externAliasDirectiveSyntax: return(ExternAliasDirective.Print(externAliasDirectiveSyntax)); case FinallyClauseSyntax finallyClauseSyntax: return(FinallyClause.Print(finallyClauseSyntax)); case FixedStatementSyntax fixedStatementSyntax: return(FixedStatement.Print(fixedStatementSyntax)); case ForEachStatementSyntax forEachStatementSyntax: return(ForEachStatement.Print(forEachStatementSyntax)); case ForEachVariableStatementSyntax forEachVariableStatementSyntax: return(ForEachVariableStatement.Print(forEachVariableStatementSyntax)); case ForStatementSyntax forStatementSyntax: return(ForStatement.Print(forStatementSyntax)); case FromClauseSyntax fromClauseSyntax: return(FromClause.Print(fromClauseSyntax)); case FunctionPointerTypeSyntax functionPointerTypeSyntax: return(FunctionPointerType.Print(functionPointerTypeSyntax)); case GenericNameSyntax genericNameSyntax: return(GenericName.Print(genericNameSyntax)); case GlobalStatementSyntax globalStatementSyntax: return(GlobalStatement.Print(globalStatementSyntax)); case GotoStatementSyntax gotoStatementSyntax: return(GotoStatement.Print(gotoStatementSyntax)); case GroupClauseSyntax groupClauseSyntax: return(GroupClause.Print(groupClauseSyntax)); case IdentifierNameSyntax identifierNameSyntax: return(IdentifierName.Print(identifierNameSyntax)); case IfStatementSyntax ifStatementSyntax: return(IfStatement.Print(ifStatementSyntax)); case ImplicitArrayCreationExpressionSyntax implicitArrayCreationExpressionSyntax: return(ImplicitArrayCreationExpression.Print( implicitArrayCreationExpressionSyntax )); case ImplicitElementAccessSyntax implicitElementAccessSyntax: return(ImplicitElementAccess.Print(implicitElementAccessSyntax)); case ImplicitObjectCreationExpressionSyntax implicitObjectCreationExpressionSyntax: return(ImplicitObjectCreationExpression.Print( implicitObjectCreationExpressionSyntax )); case ImplicitStackAllocArrayCreationExpressionSyntax implicitStackAllocArrayCreationExpressionSyntax: return(ImplicitStackAllocArrayCreationExpression.Print( implicitStackAllocArrayCreationExpressionSyntax )); case IncompleteMemberSyntax incompleteMemberSyntax: return(IncompleteMember.Print(incompleteMemberSyntax)); case InitializerExpressionSyntax initializerExpressionSyntax: return(InitializerExpression.Print(initializerExpressionSyntax)); case InterpolatedStringExpressionSyntax interpolatedStringExpressionSyntax: return(InterpolatedStringExpression.Print( interpolatedStringExpressionSyntax )); case InterpolatedStringTextSyntax interpolatedStringTextSyntax: return(InterpolatedStringText.Print(interpolatedStringTextSyntax)); case InterpolationSyntax interpolationSyntax: return(Interpolation.Print(interpolationSyntax)); case InvocationExpressionSyntax invocationExpressionSyntax: return(InvocationExpression.Print(invocationExpressionSyntax)); case IsPatternExpressionSyntax isPatternExpressionSyntax: return(IsPatternExpression.Print(isPatternExpressionSyntax)); case JoinClauseSyntax joinClauseSyntax: return(JoinClause.Print(joinClauseSyntax)); case LabeledStatementSyntax labeledStatementSyntax: return(LabeledStatement.Print(labeledStatementSyntax)); case LetClauseSyntax letClauseSyntax: return(LetClause.Print(letClauseSyntax)); case LiteralExpressionSyntax literalExpressionSyntax: return(LiteralExpression.Print(literalExpressionSyntax)); case LocalDeclarationStatementSyntax localDeclarationStatementSyntax: return(LocalDeclarationStatement.Print(localDeclarationStatementSyntax)); case LocalFunctionStatementSyntax localFunctionStatementSyntax: return(LocalFunctionStatement.Print(localFunctionStatementSyntax)); case LockStatementSyntax lockStatementSyntax: return(LockStatement.Print(lockStatementSyntax)); case MakeRefExpressionSyntax makeRefExpressionSyntax: return(MakeRefExpression.Print(makeRefExpressionSyntax)); case MemberAccessExpressionSyntax memberAccessExpressionSyntax: return(MemberAccessExpression.Print(memberAccessExpressionSyntax)); case MemberBindingExpressionSyntax memberBindingExpressionSyntax: return(MemberBindingExpression.Print(memberBindingExpressionSyntax)); case NameColonSyntax nameColonSyntax: return(NameColon.Print(nameColonSyntax)); case NameEqualsSyntax nameEqualsSyntax: return(NameEquals.Print(nameEqualsSyntax)); case NamespaceDeclarationSyntax namespaceDeclarationSyntax: return(NamespaceDeclaration.Print(namespaceDeclarationSyntax)); case NullableTypeSyntax nullableTypeSyntax: return(NullableType.Print(nullableTypeSyntax)); case ObjectCreationExpressionSyntax objectCreationExpressionSyntax: return(ObjectCreationExpression.Print(objectCreationExpressionSyntax)); case OmittedArraySizeExpressionSyntax omittedArraySizeExpressionSyntax: return(OmittedArraySizeExpression.Print(omittedArraySizeExpressionSyntax)); case OmittedTypeArgumentSyntax omittedTypeArgumentSyntax: return(OmittedTypeArgument.Print(omittedTypeArgumentSyntax)); case OrderByClauseSyntax orderByClauseSyntax: return(OrderByClause.Print(orderByClauseSyntax)); case ParameterListSyntax parameterListSyntax: return(ParameterList.Print(parameterListSyntax)); case ParameterSyntax parameterSyntax: return(Parameter.Print(parameterSyntax)); case ParenthesizedExpressionSyntax parenthesizedExpressionSyntax: return(ParenthesizedExpression.Print(parenthesizedExpressionSyntax)); case ParenthesizedLambdaExpressionSyntax parenthesizedLambdaExpressionSyntax: return(ParenthesizedLambdaExpression.Print( parenthesizedLambdaExpressionSyntax )); case ParenthesizedPatternSyntax parenthesizedPatternSyntax: return(ParenthesizedPattern.Print(parenthesizedPatternSyntax)); case ParenthesizedVariableDesignationSyntax parenthesizedVariableDesignationSyntax: return(ParenthesizedVariableDesignation.Print( parenthesizedVariableDesignationSyntax )); case PointerTypeSyntax pointerTypeSyntax: return(PointerType.Print(pointerTypeSyntax)); case PostfixUnaryExpressionSyntax postfixUnaryExpressionSyntax: return(PostfixUnaryExpression.Print(postfixUnaryExpressionSyntax)); case PredefinedTypeSyntax predefinedTypeSyntax: return(PredefinedType.Print(predefinedTypeSyntax)); case PrefixUnaryExpressionSyntax prefixUnaryExpressionSyntax: return(PrefixUnaryExpression.Print(prefixUnaryExpressionSyntax)); case PrimaryConstructorBaseTypeSyntax primaryConstructorBaseTypeSyntax: return(PrimaryConstructorBaseType.Print(primaryConstructorBaseTypeSyntax)); case QualifiedNameSyntax qualifiedNameSyntax: return(QualifiedName.Print(qualifiedNameSyntax)); case QueryBodySyntax queryBodySyntax: return(QueryBody.Print(queryBodySyntax)); case QueryContinuationSyntax queryContinuationSyntax: return(QueryContinuation.Print(queryContinuationSyntax)); case QueryExpressionSyntax queryExpressionSyntax: return(QueryExpression.Print(queryExpressionSyntax)); case RangeExpressionSyntax rangeExpressionSyntax: return(RangeExpression.Print(rangeExpressionSyntax)); case RecursivePatternSyntax recursivePatternSyntax: return(RecursivePattern.Print(recursivePatternSyntax)); case RefExpressionSyntax refExpressionSyntax: return(RefExpression.Print(refExpressionSyntax)); case RefTypeExpressionSyntax refTypeExpressionSyntax: return(RefTypeExpression.Print(refTypeExpressionSyntax)); case RefTypeSyntax refTypeSyntax: return(RefType.Print(refTypeSyntax)); case RefValueExpressionSyntax refValueExpressionSyntax: return(RefValueExpression.Print(refValueExpressionSyntax)); case RelationalPatternSyntax relationalPatternSyntax: return(RelationalPattern.Print(relationalPatternSyntax)); case ReturnStatementSyntax returnStatementSyntax: return(ReturnStatement.Print(returnStatementSyntax)); case SelectClauseSyntax selectClauseSyntax: return(SelectClause.Print(selectClauseSyntax)); case SimpleBaseTypeSyntax simpleBaseTypeSyntax: return(SimpleBaseType.Print(simpleBaseTypeSyntax)); case SimpleLambdaExpressionSyntax simpleLambdaExpressionSyntax: return(SimpleLambdaExpression.Print(simpleLambdaExpressionSyntax)); case SingleVariableDesignationSyntax singleVariableDesignationSyntax: return(SingleVariableDesignation.Print(singleVariableDesignationSyntax)); case SizeOfExpressionSyntax sizeOfExpressionSyntax: return(SizeOfExpression.Print(sizeOfExpressionSyntax)); case StackAllocArrayCreationExpressionSyntax stackAllocArrayCreationExpressionSyntax: return(StackAllocArrayCreationExpression.Print( stackAllocArrayCreationExpressionSyntax )); case SwitchExpressionSyntax switchExpressionSyntax: return(SwitchExpression.Print(switchExpressionSyntax)); case SwitchSectionSyntax switchSectionSyntax: return(SwitchSection.Print(switchSectionSyntax)); case SwitchStatementSyntax switchStatementSyntax: return(SwitchStatement.Print(switchStatementSyntax)); case ThisExpressionSyntax thisExpressionSyntax: return(ThisExpression.Print(thisExpressionSyntax)); case ThrowExpressionSyntax throwExpressionSyntax: return(ThrowExpression.Print(throwExpressionSyntax)); case ThrowStatementSyntax throwStatementSyntax: return(ThrowStatement.Print(throwStatementSyntax)); case TryStatementSyntax tryStatementSyntax: return(TryStatement.Print(tryStatementSyntax)); case TupleElementSyntax tupleElementSyntax: return(TupleElement.Print(tupleElementSyntax)); case TupleExpressionSyntax tupleExpressionSyntax: return(TupleExpression.Print(tupleExpressionSyntax)); case TupleTypeSyntax tupleTypeSyntax: return(TupleType.Print(tupleTypeSyntax)); case TypeArgumentListSyntax typeArgumentListSyntax: return(TypeArgumentList.Print(typeArgumentListSyntax)); case TypeConstraintSyntax typeConstraintSyntax: return(TypeConstraint.Print(typeConstraintSyntax)); case TypeOfExpressionSyntax typeOfExpressionSyntax: return(TypeOfExpression.Print(typeOfExpressionSyntax)); case TypeParameterConstraintClauseSyntax typeParameterConstraintClauseSyntax: return(TypeParameterConstraintClause.Print( typeParameterConstraintClauseSyntax )); case TypeParameterListSyntax typeParameterListSyntax: return(TypeParameterList.Print(typeParameterListSyntax)); case TypeParameterSyntax typeParameterSyntax: return(TypeParameter.Print(typeParameterSyntax)); case TypePatternSyntax typePatternSyntax: return(TypePattern.Print(typePatternSyntax)); case UnaryPatternSyntax unaryPatternSyntax: return(UnaryPattern.Print(unaryPatternSyntax)); case UnsafeStatementSyntax unsafeStatementSyntax: return(UnsafeStatement.Print(unsafeStatementSyntax)); case UsingDirectiveSyntax usingDirectiveSyntax: return(UsingDirective.Print(usingDirectiveSyntax)); case UsingStatementSyntax usingStatementSyntax: return(UsingStatement.Print(usingStatementSyntax)); case VariableDeclarationSyntax variableDeclarationSyntax: return(VariableDeclaration.Print(variableDeclarationSyntax)); case VariableDeclaratorSyntax variableDeclaratorSyntax: return(VariableDeclarator.Print(variableDeclaratorSyntax)); case VarPatternSyntax varPatternSyntax: return(VarPattern.Print(varPatternSyntax)); case WhenClauseSyntax whenClauseSyntax: return(WhenClause.Print(whenClauseSyntax)); case WhereClauseSyntax whereClauseSyntax: return(WhereClause.Print(whereClauseSyntax)); case WhileStatementSyntax whileStatementSyntax: return(WhileStatement.Print(whileStatementSyntax)); case WithExpressionSyntax withExpressionSyntax: return(WithExpression.Print(withExpressionSyntax)); case YieldStatementSyntax yieldStatementSyntax: return(YieldStatement.Print(yieldStatementSyntax)); default: throw new Exception("Can't handle " + syntaxNode.GetType().Name); } } finally { depth--; } }
public override int GetHashCode() { return(GenericName.GetHashCode() ^ ProductName.GetHashCode() + DeviceNumber); }