What do I enter as Assembly name in an XML file?

Posted by Lieven Cardoen on 23-Jun-2017 04:04

I'm using Actipro Software (SyntaxEditor) to edit a language of our own. 

Lexing is done by using a XML file. In the XML file you can enter a Class and the Assembly which can do more (like code completion, ...). But in my case it's an ABL .NET Class, and it's not in an assembly...

I can't get this to work. The XML file loads fine and if I omit the Class/Assembly, then the Editor works fine. 

But with next line: 

SyntaxLanguageTypeName="be.mips.ablframework.gui.mispl.MisplSyntaxLanguage, be.mips.ablframework.gui.mispl" 

things Crash. 

Any idea how ABL solves this? In my C# Visual Studio project it's: 

SyntaxLanguageTypeName="MisplSyntaxEditor.MisplSyntaxLanguage, MisplSyntaxEditor" 

With MisplSyntaxEditor being the Assembly name end MisplSyntaxEditor.MisplSyntaxLanguage being package + Class name.

So SyntaxLanguageTypeName = "Package:ClassName, Assembly" 

But in ABL there are no assemblies... 

Kind regards, Lieven Cardoen 

All Replies

Posted by Mike Fechner on 23-Jun-2017 04:14

ABL types cannot be loaded as assemblies.
Best chance you may have is to define .NET Interfaces for everything the .NET side (your editor) needs to “see”. ABL classes implementing those interfaces (and inheriting from System.Object) can be used from the .NET side (only the members – methods, properties, events – defined in the interface are visible and accessible to .NET).
But .NET cannot NEW an ABL object, even when it implements a .NET interface type.  
Your editor will probably use .NET reflection. This requires System.Type’s not Progress.Lang.Class. Hybrid ABL types have both 😊 – but the System.Type view of it, will only contain methods, properties, events of what’s required for the .NET interfaces – or what overrides .NET methods.
The .NET Types for the hybrids will only be emitted (created) in the dynamic assembly, once an instance of that type was NEW’ed from the ABL side.
Laura will probably correct me in a few hours 😊

Posted by Laura Stern on 05-Jul-2017 08:28

No comment from me since I was on vacation!  Actually, everything you said is CORRECT :-)  Though since I didn't understand the question, I have no idea if you answered it or not.  Presumably yes, since there were no further posts.

This thread is closed