Does Knop Support Jason's Custom Tag Loader?

View: New views
5 Messages — Rating Filter:   Alert me  

Does Knop Support Jason's Custom Tag Loader?

by Steve Piercy :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Rather than toss the Knop tags into LassoLibraries, I would like to put them in a custom location to make it easier to manage updates, but it looks like the tags require the following modification.  If so, this is a feature request.

http://devblog.jasonhuck.com/2008/04/10/using-namespaces-to-load-lasso-tags-into-memory/

    In its current incarnation, it’s important that each file loaded
    with the tag loader contain a tag with the same name as the
    file. Otherwise, that file will be reloaded every time,
    regardless of whether it’s necessary. So, for instance, if you
    have all of the tags in the foo_ namespace in a single file
    called foo_library.inc, you’ll want to include a placeholder tag
    to register the library with the tag loader. I typically just
    define a simple tag which returns “Loaded” and place it at the
    end of the file (so that it only loads if there are no other
    errors):
   
    [
        define_tag('foo_bar');
            ...
        /define_tag;
     
        ...
     
        define_tag('foo_library');
            return('Loaded');
        /define_tag;
    ]

--steve

-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
Steve Piercy               Web Site Builder               Soquel, CA
<web@...>                  <http://www.StevePiercy.com/>

--
#############################################################
This message is sent to you because you are subscribed to
the mailing list <knop@...>.
To unsubscribe, E-mail to: <knop-off@...>
Send administrative queries to  <knop-request@...>
List archive http://www.nabble.com/Knop-Framework-Discussion-f29076.html
Project homepage http://montania.se/projects/knop/
Google Code has the latest downloads at http://code.google.com/p/knop/

Re: Does Knop Support Jason's Custom Tag Loader?

by Johan Solve-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

Would you use this to load the entire knop.lasso file or the individual source files separately? (form.inc etc)

At 11.39 -0700 2009-07-02, Steve Piercy - Web Site Builder wrote:

>Rather than toss the Knop tags into LassoLibraries, I would like to put them in a custom location to make it easier to manage updates, but it looks like the tags require the following modification.  If so, this is a feature request.
>
>http://devblog.jasonhuck.com/2008/04/10/using-namespaces-to-load-lasso-tags-into-memory/
>
>    In its current incarnation, it's important that each file loaded
>    with the tag loader contain a tag with the same name as the
>    file. Otherwise, that file will be reloaded every time,
>    regardless of whether it's necessary. So, for instance, if you
>    have all of the tags in the foo_ namespace in a single file
>    called foo_library.inc, you'll want to include a placeholder tag
>    to register the library with the tag loader. I typically just
>    define a simple tag which returns "Loaded" and place it at the
>    end of the file (so that it only loads if there are no other
>    errors):
>
>    [
>        define_tag('foo_bar');
>            ...
>        /define_tag;
>
>        ...
>
>        define_tag('foo_library');
>            return('Loaded');
>        /define_tag;
>    ]
>
>--steve
>
>-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
>Steve Piercy               Web Site Builder               Soquel, CA
><web@...>                  <http://www.StevePiercy.com/>
>
>--
>#############################################################
>This message is sent to you because you are subscribed to
>the mailing list <knop@...>.
>To unsubscribe, E-mail to: <knop-off@...>
>Send administrative queries to  <knop-request@...>
>List archive http://www.nabble.com/Knop-Framework-Discussion-f29076.html
>Project homepage http://montania.se/projects/knop/
>Google Code has the latest downloads at http://code.google.com/p/knop/


--
     Johan Sölve    [FSA Member, Lasso Partner]
     Web Application/Lasso/FileMaker Developer
     MONTANIA SOFTWARE & SOLUTIONS
http://www.montania.se   mailto:joh-n@...
 (spam-safe email address, replace '-' with 'a')

--
#############################################################
This message is sent to you because you are subscribed to
the mailing list <knop@...>.
To unsubscribe, E-mail to: <knop-off@...>
Send administrative queries to  <knop-request@...>
List archive http://www.nabble.com/Knop-Framework-Discussion-f29076.html
Project homepage http://montania.se/projects/knop/
Google Code has the latest downloads at http://code.google.com/p/knop/

Re: Does Knop Support Jason's Custom Tag Loader?

by Steve Piercy :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

I had a feeling you would ask that.  ;)

Ideally having the flexibility to load either would be nice, but if I had to choose one, I would prefer the individual files.  When I study Knop, I usually look in the individual file to focus my search.  Also it is easy to forget to rebuild the single file when an individual file changes.

--steve


On Thursday, July 2, 2009, inbox_js@... (Johan Solve) pronounced:

>Would you use this to load the entire knop.lasso file or the individual source files
>separately? (form.inc etc)
>
>At 11.39 -0700 2009-07-02, Steve Piercy - Web Site Builder wrote:
>>Rather than toss the Knop tags into LassoLibraries, I would like to put them in a
>custom location to make it easier to manage updates, but it looks like the tags
>require the following modification.  If so, this is a feature request.
>>
>>http://devblog.jasonhuck.com/2008/04/10/using-namespaces-to-load-lasso-tags-into-
>memory/
>>
>>    In its current incarnation, it's important that each file loaded
>>    with the tag loader contain a tag with the same name as the
>>    file. Otherwise, that file will be reloaded every time,
>>    regardless of whether it's necessary. So, for instance, if you
>>    have all of the tags in the foo_ namespace in a single file
>>    called foo_library.inc, you'll want to include a placeholder tag
>>    to register the library with the tag loader. I typically just
>>    define a simple tag which returns "Loaded" and place it at the
>>    end of the file (so that it only loads if there are no other
>>    errors):
>>  
>>    [
>>        define_tag('foo_bar');
>>            ...
>>        /define_tag;
>>    
>>        ...
>>    
>>        define_tag('foo_library');
>>            return('Loaded');
>>        /define_tag;
>>    ]
>>
>>--steve
>>
>>-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
>>Steve Piercy               Web Site Builder               Soquel, CA
>><web@...>                  <http://www.StevePiercy.com/>
>>
>>--
>>#############################################################
>>This message is sent to you because you are subscribed to
>>the mailing list <knop@...>.
>>To unsubscribe, E-mail to: <knop-off@...>
>>Send administrative queries to  <knop-request@...>
>>List archive http://www.nabble.com/Knop-Framework-Discussion-f29076.html
>>Project homepage http://montania.se/projects/knop/
>>Google Code has the latest downloads at http://code.google.com/p/knop/
>
>
>--
>     Johan Sölve    [FSA Member, Lasso Partner]
>     Web Application/Lasso/FileMaker Developer
>     MONTANIA SOFTWARE & SOLUTIONS
>http://www.montania.se   mailto:joh-n@...
> (spam-safe email address, replace '-' with 'a')
>

-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
Steve Piercy               Web Site Builder               Soquel, CA
<web@...>                  <http://www.StevePiercy.com/>

--
#############################################################
This message is sent to you because you are subscribed to
the mailing list <knop@...>.
To unsubscribe, E-mail to: <knop-off@...>
Send administrative queries to  <knop-request@...>
List archive http://www.nabble.com/Knop-Framework-Discussion-f29076.html
Project homepage http://montania.se/projects/knop/
Google Code has the latest downloads at http://code.google.com/p/knop/

Re: Does Knop Support Jason's Custom Tag Loader?

by Johan Solve-2 :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

So the placeholder tag names would be util, base, form, database, lang etc. Seems like asking for trouble, unless we rename the source files to be slightly more unique.

On the other hand, the tag loader could be modified to look for a tag name wrapped in something to make it reasonably unique, for example util_loaded, base_loaded etc and knop_loaded for the knop.lasso file. Could you live with hacking Jason's tag loader to do that?


At 13.17 -0700 2009-07-02, Steve Piercy - Web Site Builder wrote:

>I had a feeling you would ask that.  ;)
>
>Ideally having the flexibility to load either would be nice, but if I had to choose one, I would prefer the individual files.  When I study Knop, I usually look in the individual file to focus my search.  Also it is easy to forget to rebuild the single file when an individual file changes.
>
>--steve
>
>
>On Thursday, July 2, 2009, inbox_js@... (Johan Solve) pronounced:
>
>>Would you use this to load the entire knop.lasso file or the individual source files
>>separately? (form.inc etc)
>>
>>At 11.39 -0700 2009-07-02, Steve Piercy - Web Site Builder wrote:
>>>Rather than toss the Knop tags into LassoLibraries, I would like to put them in a
>>custom location to make it easier to manage updates, but it looks like the tags
>>require the following modification.  If so, this is a feature request.
>>>
>>>http://devblog.jasonhuck.com/2008/04/10/using-namespaces-to-load-lasso-tags-into-
>>memory/
>>>
>>>    In its current incarnation, it's important that each file loaded
>>>    with the tag loader contain a tag with the same name as the
>>>    file. Otherwise, that file will be reloaded every time,
>>>    regardless of whether it's necessary. So, for instance, if you
>>>    have all of the tags in the foo_ namespace in a single file
>>>    called foo_library.inc, you'll want to include a placeholder tag
>>>    to register the library with the tag loader. I typically just
>>>    define a simple tag which returns "Loaded" and place it at the
>>>    end of the file (so that it only loads if there are no other
>>>    errors):
>>>
>>>    [
>>>        define_tag('foo_bar');
>>>            ...
>>>        /define_tag;
>>>
>>>        ...
>>>
>>>        define_tag('foo_library');
>>>            return('Loaded');
>>>        /define_tag;
>>>    ]
>>>
>>>--steve
>>>
>>>-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
>>>Steve Piercy               Web Site Builder               Soquel, CA
>>><web@...>                  <http://www.StevePiercy.com/>
>>>
>>>--
>>>#############################################################
>>>This message is sent to you because you are subscribed to
>>>the mailing list <knop@...>.
>>>To unsubscribe, E-mail to: <knop-off@...>
>>>Send administrative queries to  <knop-request@...>
>>>List archive http://www.nabble.com/Knop-Framework-Discussion-f29076.html
>>>Project homepage http://montania.se/projects/knop/
>>>Google Code has the latest downloads at http://code.google.com/p/knop/
>>
>>
>>--
>>     Johan Sölve    [FSA Member, Lasso Partner]
>>     Web Application/Lasso/FileMaker Developer
>>     MONTANIA SOFTWARE & SOLUTIONS
>>http://www.montania.se   mailto:joh-n@...
>> (spam-safe email address, replace '-' with 'a')
>>
>
>-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
>Steve Piercy               Web Site Builder               Soquel, CA
><web@...>                  <http://www.StevePiercy.com/>
>
>--
>#############################################################
>This message is sent to you because you are subscribed to
>the mailing list <knop@...>.
>To unsubscribe, E-mail to: <knop-off@...>
>Send administrative queries to  <knop-request@...>
>List archive http://www.nabble.com/Knop-Framework-Discussion-f29076.html
>Project homepage http://montania.se/projects/knop/
>Google Code has the latest downloads at http://code.google.com/p/knop/


--
     Johan Sölve    [FSA Member, Lasso Partner]
     Web Application/Lasso/FileMaker Developer
     MONTANIA SOFTWARE & SOLUTIONS
http://www.montania.se   mailto:joh-n@...
 (spam-safe email address, replace '-' with 'a')

--
#############################################################
This message is sent to you because you are subscribed to
the mailing list <knop@...>.
To unsubscribe, E-mail to: <knop-off@...>
Send administrative queries to  <knop-request@...>
List archive http://www.nabble.com/Knop-Framework-Discussion-f29076.html
Project homepage http://montania.se/projects/knop/
Google Code has the latest downloads at http://code.google.com/p/knop/

Re: Does Knop Support Jason's Custom Tag Loader?

by Jason Huck :: Rate this Message:

Reply to Author | View Threaded | Show Only this Message

That was just a simple workaround for the rare case when I didn't have
each tag in its own file. For working with libraries like yours, it
might make more sense to just store each successfully loaded file in a
global registry to check against...

- jason




On Thu, Jul 2, 2009 at 4:36 PM, Johan Solve<inbox_js@...> wrote:

> So the placeholder tag names would be util, base, form, database, lang etc. Seems like asking for trouble, unless we rename the source files to be slightly more unique.
>
> On the other hand, the tag loader could be modified to look for a tag name wrapped in something to make it reasonably unique, for example util_loaded, base_loaded etc and knop_loaded for the knop.lasso file. Could you live with hacking Jason's tag loader to do that?
>
>
> At 13.17 -0700 2009-07-02, Steve Piercy - Web Site Builder wrote:
>>I had a feeling you would ask that.  ;)
>>
>>Ideally having the flexibility to load either would be nice, but if I had to choose one, I would prefer the individual files.  When I study Knop, I usually look in the individual file to focus my search.  Also it is easy to forget to rebuild the single file when an individual file changes.
>>
>>--steve
>>
>>
>>On Thursday, July 2, 2009, inbox_js@... (Johan Solve) pronounced:
>>
>>>Would you use this to load the entire knop.lasso file or the individual source files
>>>separately? (form.inc etc)
>>>
>>>At 11.39 -0700 2009-07-02, Steve Piercy - Web Site Builder wrote:
>>>>Rather than toss the Knop tags into LassoLibraries, I would like to put them in a
>>>custom location to make it easier to manage updates, but it looks like the tags
>>>require the following modification.  If so, this is a feature request.
>>>>
>>>>http://devblog.jasonhuck.com/2008/04/10/using-namespaces-to-load-lasso-tags-into-
>>>memory/
>>>>
>>>>    In its current incarnation, it's important that each file loaded
>>>>    with the tag loader contain a tag with the same name as the
>>>>    file. Otherwise, that file will be reloaded every time,
>>>>    regardless of whether it's necessary. So, for instance, if you
>>>>    have all of the tags in the foo_ namespace in a single file
>>>>    called foo_library.inc, you'll want to include a placeholder tag
>>>>    to register the library with the tag loader. I typically just
>>>>    define a simple tag which returns "Loaded" and place it at the
>>>>    end of the file (so that it only loads if there are no other
>>>>    errors):
>>>>
>>>>    [
>>>>        define_tag('foo_bar');
>>>>            ...
>>>>        /define_tag;
>>>>
>>>>        ...
>>>>
>>>>        define_tag('foo_library');
>>>>            return('Loaded');
>>>>        /define_tag;
>>>>    ]
>>>>
>>>>--steve
>>>>
>>>>-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
>>>>Steve Piercy               Web Site Builder               Soquel, CA
>>>><web@...>                  <http://www.StevePiercy.com/>
>>>>
>>>>--
>>>>#############################################################
>>>>This message is sent to you because you are subscribed to
>>>>the mailing list <knop@...>.
>>>>To unsubscribe, E-mail to: <knop-off@...>
>>>>Send administrative queries to  <knop-request@...>
>>>>List archive http://www.nabble.com/Knop-Framework-Discussion-f29076.html
>>>>Project homepage http://montania.se/projects/knop/
>>>>Google Code has the latest downloads at http://code.google.com/p/knop/
>>>
>>>
>>>--
>>>     Johan Sölve    [FSA Member, Lasso Partner]
>>>     Web Application/Lasso/FileMaker Developer
>>>     MONTANIA SOFTWARE & SOLUTIONS
>>>http://www.montania.se   mailto:joh-n@...
>>> (spam-safe email address, replace '-' with 'a')
>>>
>>
>>-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
>>Steve Piercy               Web Site Builder               Soquel, CA
>><web@...>                  <http://www.StevePiercy.com/>
>>
>>--
>>#############################################################
>>This message is sent to you because you are subscribed to
>>the mailing list <knop@...>.
>>To unsubscribe, E-mail to: <knop-off@...>
>>Send administrative queries to  <knop-request@...>
>>List archive http://www.nabble.com/Knop-Framework-Discussion-f29076.html
>>Project homepage http://montania.se/projects/knop/
>>Google Code has the latest downloads at http://code.google.com/p/knop/
>
>
> --
>     Johan Sölve    [FSA Member, Lasso Partner]
>     Web Application/Lasso/FileMaker Developer
>     MONTANIA SOFTWARE & SOLUTIONS
> http://www.montania.se   mailto:joh-n@...
>  (spam-safe email address, replace '-' with 'a')
>
> --
> #############################################################
> This message is sent to you because you are subscribed to
> the mailing list <knop@...>.
> To unsubscribe, E-mail to: <knop-off@...>
> Send administrative queries to  <knop-request@...>
> List archive http://www.nabble.com/Knop-Framework-Discussion-f29076.html
> Project homepage http://montania.se/projects/knop/
> Google Code has the latest downloads at http://code.google.com/p/knop/
>



--
tagSwap.net :: Open Source Lasso Code
<http://tagSwap.net/>

--
#############################################################
This message is sent to you because you are subscribed to
the mailing list <knop@...>.
To unsubscribe, E-mail to: <knop-off@...>
Send administrative queries to  <knop-request@...>
List archive http://www.nabble.com/Knop-Framework-Discussion-f29076.html
Project homepage http://montania.se/projects/knop/
Google Code has the latest downloads at http://code.google.com/p/knop/