Plug-in Find template elements by type and name

With this plug-in can scan all content classes of all folders searching for elements of a specific type and/or named accordingly by a given pattern. It come back to you with a table of all found content class elements with folder, content class, element name.

This plug-in is one of my favourites, because it ensures the consistent change on all content classes by delivering a 100% list, what content classes are affected.

I use in my content classes often elements with same name and type consistently per project. If I need to change the template code around an element, I need a working list, which content classes I had to update. This plug-in provide me with exactly such kind of working list.

Location in SmartTree
You found the plug-in under Administer Content Class.

How it works
First you get a dialog where you have to choose the type of element from a drop down list. You can choose from all element types jRQL supports. Additionally you can enter a pattern (only one *) to search by element name. Of course you can enter a fix element name as well.

After clicking the button Find elements the plug-in checks all content class folders for all content classes, what can take some time. Therefore the plug-in tells you the progress this way.

If the scan is finished the elements found are presented in a tabular fashion.

The plug-in tells you how many elements found and offer a quick printing possibility. I usually copy this table to Excel and update/check each content class one by one.

This plug-in can be installed using the combined setup routine for all jRQL API based plug-ins. Follow the instruction in this blog to download the installer and configure the plug-ins you want.

For API developers
The plug-in is quite old and not based on the current functionality. Today I would start with the method to get all content classes (in API still named Template) Project > getAllTemplates().

The element searching is done by asking a Template for the elements matching the given name pattern by one of the methods Template > getTemplateElementsByType().

Post a comment or leave a trackback: Trackback URL.

Leave a Reply

Fill in your details below or click an icon to log in: Logo

You are commenting using your account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s

%d bloggers like this: