Get() public static method

public static Get ( string name ) : SimplTypesScope
name string
return SimplTypesScope
Beispiel #1
0
        private bool ResolveScopeAnnotation(string scopeAnnotation)
        {
            SimplTypesScope scope = SimplTypesScope.Get(scopeAnnotation);

            if (scope != null)
            {
                List <ClassDescriptor> scopeClassDescriptors = scope.GetClassDescriptors();
                InitTagClassDescriptorsArrayList(scopeClassDescriptors.Count);
                foreach (ClassDescriptor classDescriptor in scopeClassDescriptors)
                {
                    String tagName = classDescriptor.TagName;
                    polymorphClassDescriptors.Put(tagName, classDescriptor);
                    polymorphClasses.Put(tagName, classDescriptor.DescribedClass);
                }
            }
            return(scope != null);
        }
Beispiel #2
0
        private bool ResolveScopeAttribute(string scopeAttributeValue)
        {
            SimplTypesScope scope = SimplTypesScope.Get(scopeAttributeValue);

            if (scope != null)
            {
                List <ClassDescriptor> scopeClassDescriptors = scope.ClassDescriptors;
                InitPolymorphicClassDescriptorsList(scopeClassDescriptors.Count);
                foreach (var scopeClassDescriptor in scopeClassDescriptors)
                {
                    polymorphClassDescriptors.Put(scopeClassDescriptor.TagName, scopeClassDescriptor);
                    polymorphClasses.Put(scopeClassDescriptor.TagName, scopeClassDescriptor.DescribedClass);
                    tlvClassDescriptors.Put(_tagName.GetHashCode(), scopeClassDescriptor);
                }
            }

            return(scope != null);
        }