예제 #1
0
        public static string GetEventRef(IMember property, IEmitter emitter, bool remove = false, bool noOverload = false, bool ignoreInterface = false, bool withoutTypeParams = false, bool skipPrefix = false)
        {
            var attrName = emitter.GetEntityNameFromAttr(property, remove);

            if (!String.IsNullOrEmpty(attrName))
            {
                return(Helpers.AddInterfacePrefix(property, emitter, ignoreInterface, attrName, remove));
            }

            if (!noOverload)
            {
                var overloads = OverloadsCollection.Create(emitter, property, remove);
                return(overloads.GetOverloadName(ignoreInterface, skipPrefix ? null : Helpers.GetAddOrRemove(!remove), withoutTypeParams));
            }

            var name = emitter.GetEntityName(property);

            return(skipPrefix ? name : Helpers.GetAddOrRemove(!remove, name));
        }