Follow Techotopia on Twitter

On-line Guides
All Guides
eBook Store
iOS / Android
Linux for Beginners
Office Productivity
Linux Installation
Linux Security
Linux Utilities
Linux Virtualization
Linux Kernel
System/Network Admin
Programming
Scripting Languages
Development Tools
Web Development
GUI Toolkits/Desktop
Databases
Mail Systems
openSolaris
Eclipse Documentation
Techotopia.com
Virtuatopia.com
Answertopia.com

How To Guides
Virtualization
General System Admin
Linux Security
Linux Filesystems
Web Servers
Graphics & Desktop
PC Hardware
Windows
Problem Solutions
Privacy Policy

  




 

 

Eclipse Web Tools Guide
Previous Page Home Next Page

Editing snippet items

To modify an existing item in a Snippets drawer, complete the steps listed below. If you have just completed the task Adding an item to a snippets drawer and the Customize Palette window is still open, you can skip steps 1 and 2.
  1. In the Snippets view, right-click the name of the item that you want to modify, and select Customize.
  2. Optionally, type a new name and a new description for the item.
  3. To declare a variable, click New and type the variable's name, description, and default value.
  4. To edit an existing variable, type over the existing values.
  5. To edit the Template Pattern field, type into the field, cut and paste into the field, or, if you have defined one or more variables, click the Insert Variable Placeholder button, and double-click the name of the variable that you want to insert. For example, if you have declare variables named uri and prefix, clicking the button brings up a menu that contains those names. Double-clicking uri inserts ${uri}, as in the following example:
    <%@ taglib uri="${uri}" prefix="${prefix}" %>
    Later, when you insert the snippet into a file, ${uri} and ${prefix} are each converted to the default value declared in the Variables table. Users can replace the default values in the Insert Template: Item_name dialog at insertion time.
  6. Click OK.
The modified item will be added to the list of items in the appropriate drawer.

 
 
  Published under the terms of the Eclipse Public License Version 1.0 ("EPL") Design by Interspire