Manager Templates (how to..)

Posts   
 
    
Waldo
User
Posts: 9
Joined: 15-Feb-2006
# Posted on: 07-Mar-2006 03:11:28   

Hi all,

These questions may have been asked before...but I was interested to know how to generate "Manager classes" from my LLBLGen Entities.

I have downloaded the following "Manager Templates":

EntityManagerBaseTemplate.lpt EntityManagerTemplate.lpt EntityManagerTestSuiteBaseTemplate.lpt ManagerBaseTemplate.lpt ManagerTestSuitBaseTemplate.lpt PrefectPathElementCollectionTemplate.lpt

I have also downloaded the SDK and Template Studio.

Once I open up my project (*.lgp) using Template Studio, what templates listed above do I need to load? What does each one do? Do I need to do any modifications to each to suit my project needs? Where should these templates reside on my file system?

I'm new at all of this, so any help that you can provide would be really appreciated. Great product by the waysimple_smile

Regards, David

Otis avatar
Otis
LLBLGen Pro Team
Posts: 39776
Joined: 17-Aug-2003
# Posted on: 07-Mar-2006 20:16:20   

You should pick the new generator config you get in the drop down at the top of the code generation form in the designer and then teh custom C# templateset, and the templates should work. You have to download the complete template folder and store that in teh llblgen pro folder (it contains drivers/taskperformers folders so it will place the files in the right folders)

Frans Bouma | Lead developer LLBLGen Pro
superzaif
User
Posts: 5
Joined: 31-Oct-2005
# Posted on: 27-Mar-2007 04:08:49   

I am a newb when it comes to templates. I have scanned these forums regarding using the manager templates without any luck. Here is what I have tried:

Downloaded and add the files as follows: --> Manager.Template.templatebindings in Templates folder. --> *.lpt files in the Templates\Gallery folder --> Manager.Templates.tasks file in the Tasks Folder.

Then I attempted to Generate as follows: --> Hit F7 to get to start the code gen process, selected C#, .Net 2.0, Adapter --> Clicked on "Task Queue to execute" window --> Added the "Manager Templates" tasks -- Clicked on Start Generator

It breaks with the following error: Task: 'SD.Tasks.Adapter.EntityCollectionClassGenerator' aborted process.

Here are the exception details:


Source:
SD.LLBLGen.Pro.LptParser

Message:
Compilation of templates threw errors: 
Error CS1001, at line: 21, pos: 7: Identifier expected
Error CS1001, at line: 28, pos: 11: Identifier expected
Error CS1519, at line: 42, pos: 3: Invalid token '<' in class, struct, or interface member declaration
Error CS1002, at line: 42, pos: 37: ; expected
Error CS1519, at line: 42, pos: 86: Invalid token ')' in class, struct, or interface member declaration
Error CS1031, at line: 49, pos: 33: Type expected
Error CS1519, at line: 49, pos: 47: Invalid token '%' in class, struct, or interface member declaration
Error CS1002, at line: 49, pos: 66: ; expected
Error CS1520, at line: 51, pos: 11: Class, struct, or interface method must have a return type
Error CS1001, at line: 51, pos: 28: Identifier expected
Error CS1031, at line: 51, pos: 30: Type expected
Error CS1518, at line: 60, pos: 17: Expected class, delegate, enum, interface, or struct
Error CS1518, at line: 62, pos: 43: Expected class, delegate, enum, interface, or struct
Error CS1518, at line: 75, pos: 17: Expected class, delegate, enum, interface, or struct
Error CS1022, at line: 79, pos: 5: Type or namespace definition, or end-of-file expected

Exception:
-----[Core exception]--------------------
   at SD.LLBLGen.Pro.LptParser.DotNetTemplateEngine.CompileForTDLIncludeTemplates(IGenerator executingGenerator, ITask taskDefinition)
   at SD.LLBLGen.Pro.TaskPerformers.CodeEmitter.Perform(IGenerator executingGenerator, ITask taskDefinition, Dictionary`2 parameters)
   at SD.LLBLGen.Pro.ApplicationCore.Tasks.Task.Perform(IGenerator executingGenerator, LogNode parentNode)
   at SD.LLBLGen.Pro.ApplicationCore.Tasks.TaskGroup.Perform(IGenerator executingGenerator, LogNode parentNode)
   at SD.LLBLGen.Pro.ApplicationCore.Tasks.TaskGroup.Perform(IGenerator executingGenerator, LogNode parentNode)
   at SD.LLBLGen.Pro.GeneratorCore.Generator.Start(ITaskGroup tasksToExecute, Project projectDefinition, Language languageToUse, Platform platformToUse, List`1 templateBindingsToUse, String templateGroupToUse, ApplicationConfiguration configurationSettings)
   at SD.LLBLGen.Pro.Gui.Forms.MainWindow.StartGeneratorProcess()

Please help me through this as I am lost.

Walaa avatar
Walaa
Support Team
Posts: 14987
Joined: 21-Aug-2005
# Posted on: 27-Mar-2007 09:11:36   

Would you please create a new thread, rather than using an old one? Posting Guidelines: http://www.llblgen.com/TinyForum/Messages.aspx?ThreadID=7723 I'll close this thread. Thanks.