GetFormalParameter() 공개 메소드

Provides the formal parameter whose name corresponds to the name provided
public GetFormalParameter ( string name ) : Parameter
name string
리턴 Parameter
예제 #1
0
        /// <summary>
        ///     Sets the update information for this procedure
        /// </summary>
        /// <param name="source">The source procedure this procedure updates</param>
        public override void SetUpdateInformation(ModelElement source)
        {
            base.SetUpdateInformation(source);
            Procedure sourceProcedure = (Procedure)source;

            // In addition to indicating the function's update information, we need to create links for each parameter
            foreach (Parameter parameter in FormalParameters)
            {
                Parameter baseParameter = sourceProcedure.GetFormalParameter(parameter.Name);
                if (baseParameter != null)
                {
                    parameter.SetUpdateInformation(baseParameter);
                }
            }

            foreach (Rule rule in Rules)
            {
                Rule baseRule = sourceProcedure.FindRule(rule.Name);
                if (baseRule != null)
                {
                    rule.SetUpdateInformation(baseRule);
                }
            }
        }