Exemplo n.º 1
0
 public StructGenerator(Dictionary <string, TypeDeclaration> typeData, NameLookup nameLookup, NamespaceMap namespaceMap, CommentGenerator commentGenerator)
 {
     this.typeData         = typeData;
     this.nameLookup       = nameLookup;
     this.namespaceMap     = namespaceMap;
     this.commentGenerator = commentGenerator;
 }
Exemplo n.º 2
0
 public DelegateGenerator(IEnumerable <DelegateDeclaration> delegates, Dictionary <string, TypeDeclaration> typeData, NamespaceMap namespaceMap, NameLookup nameLookup)
 {
     this.delegates    = delegates;
     this.typeData     = typeData;
     this.namespaceMap = namespaceMap;
     this.nameLookup   = nameLookup;
 }
Exemplo n.º 3
0
 public PInvokeGenerator(IEnumerable <CommandDeclaration> commands, IEnumerable <ExtensionDeclaration> extensions, NamespaceMap namespaceMap, NameLookup nameLookup)
 {
     this.extensions   = extensions.ToDictionary(x => x.Name);
     this.commands     = commands;
     this.namespaceMap = namespaceMap;
     this.nameLookup   = nameLookup;
 }
Exemplo n.º 4
0
 public MarshalledStructGenerator(Dictionary <string, TypeDeclaration> typeData, NameLookup nameLookup, IEnumerable <IMemberPatternRule> patternRules, NamespaceMap namespaceMap)
 {
     this.typeData     = typeData;
     this.nameLookup   = nameLookup;
     this.patternRules = patternRules;
     this.namespaceMap = namespaceMap;
 }
Exemplo n.º 5
0
 public HandleExtensionsGenerator(Dictionary <string, TypeDeclaration> typeData, NameLookup nameLookup, IEnumerable <CommandDeclaration> commands, NamespaceMap namespaceMap, HandleGenerator handleGenerator)
 {
     this.typeData        = typeData;
     this.nameLookup      = nameLookup;
     this.commands        = commands;
     this.namespaceMap    = namespaceMap;
     this.handleGenerator = handleGenerator;
 }
Exemplo n.º 6
0
 public HandleGenerator(Dictionary <string, TypeDeclaration> typeData, NameLookup nameLookup, IEnumerable <CommandDeclaration> commands, IEnumerable <IMarshalValueRule> marshallingRules, IEnumerable <IMemberPatternRule> memberPatternRules, ParsedExpressionTokenCheck tokenCheck, NamespaceMap namespaceMap)
 {
     this.typeData           = typeData;
     this.nameLookup         = nameLookup;
     this.commands           = commands.GroupBy(x => x.HandleTypeName).ToDictionary(x => x.Key, x => x.AsEnumerable());
     this.marshallingRules   = marshallingRules;
     this.memberPatternRules = memberPatternRules;
     this.tokenCheck         = tokenCheck;
     this.namespaceMap       = namespaceMap;
 }
Exemplo n.º 7
0
        public NameLookup(IEnumerable <TypeNameMapping> nameMappings, Dictionary <string, TypeDeclaration> typeData, NamespaceMap namespaceMap)
        {
            this.nameMapping = nameMappings.GroupBy(x => x.VkName)
                               .Select(x => x.OrderByDescending(y => y.Priority).First())
                               .ToDictionary(x => x.VkName, x =>
            {
                var namespaces = namespaceMap.Map(x.Extension).Append(x.OutputName);

                return(string.Join(".", namespaces));
            });
            this.typeData     = typeData;
            this.namespaceMap = namespaceMap;
        }
Exemplo n.º 8
0
 public PInvokeGenerator(IEnumerable <CommandDeclaration> commands, NamespaceMap namespaceMap, NameLookup nameLookup)
 {
     this.commands     = commands;
     this.namespaceMap = namespaceMap;
     this.nameLookup   = nameLookup;
 }
Exemplo n.º 9
0
 public ExceptionGenerator(IEnumerable <EnumDeclaration> enums, NamespaceMap namespaceMap, CommentGenerator commentGenerator)
 {
     this.resultEnum       = enums.Single(x => x.VkName == "VkResult");
     this.namespaceMap     = namespaceMap;
     this.commentGenerator = commentGenerator;
 }
Exemplo n.º 10
0
 public ExtensionConstantGenerator(IEnumerable <ExtensionInfo> extensions, NameLookup nameLookup, NamespaceMap namespaceMap)
 {
     this.extensions   = extensions;
     this.nameLookup   = nameLookup;
     this.namespaceMap = namespaceMap;
 }
Exemplo n.º 11
0
 public EnumGenerator(IEnumerable <EnumDeclaration> enums, NamespaceMap namespaceMap, CommentGenerator commentGenerator)
 {
     this.enums            = enums;
     this.namespaceMap     = namespaceMap;
     this.commentGenerator = commentGenerator;
 }
Exemplo n.º 12
0
 public EnumGenerator(IEnumerable <EnumDeclaration> enums, NamespaceMap namespaceMap)
 {
     this.enums        = enums;
     this.namespaceMap = namespaceMap;
 }