コード例 #1
0
        internal static void AddAbstractAccessorVisibilityModifierSteps(
            this List <ISourceCodeBuilderStep> steps,
            AbstractAccessorVisibilityModifier visibility)
        {
            if (visibility == AbstractAccessorVisibilityModifier.None)
            {
                return;
            }

            if (visibility == AbstractAccessorVisibilityModifier.ProtectedInternal)
            {
                steps.Add(new WriteAbstractAccessorVisibilityModifier(AbstractAccessorVisibilityModifier.Protected));
                steps.Add(new WriteWhitespace());
                steps.Add(new WriteAbstractAccessorVisibilityModifier(AbstractAccessorVisibilityModifier.Internal));
                steps.Add(new WriteWhitespace());
            }
            else
            {
                steps.Add(new WriteAbstractAccessorVisibilityModifier(visibility));
                steps.Add(new WriteWhitespace());
            }
        }
 public WriteAbstractAccessorVisibilityModifier(AbstractAccessorVisibilityModifier modifier)
 {
     Modifier = modifier;
 }