Velocity
  1. Velocity
  2. VELOCITY-560

Should ExtendedProperties.convertProperties instead of ExtendedProperties.putAll

    Details

    • Type: Bug Bug
    • Status: Resolved
    • Priority: Minor Minor
    • Resolution: Fixed
    • Affects Version/s: 1.5
    • Fix Version/s: 1.6
    • Component/s: Documentation
    • Labels:
      None
    • Environment:
      Any

      Description

      In the developer-guide document (http://velocity.apache.org/engine/releases/velocity-1.5/developer-guide.html), there is a section, which talks about using ExtendedProperties to initialize VelocityEngine (at the bottom of #miscellaneousdetails).

      At least for me, it didn't work as described. Instead of:
      ExtendedProperties eprops = new ExtendedProperties();

      // if you already have a Properties object do this
      eprops.putAll(props);

      It should be:
      ExtendedProperties eprops = null;
      if (props==null)

      { eprops = new ExtendedProperties(); }

      else

      { eprops = convertProperties(props); }

      This is obviously very minor, but may save someone 15 minutes.

        Activity

        Hide
        Will Glass-Husain added a comment -

        Thanks for reporting this. We'll fix the docs.

        Show
        Will Glass-Husain added a comment - Thanks for reporting this. We'll fix the docs.
        Hide
        Nathan Bubna added a comment -

        fixed. thanks!

        Show
        Nathan Bubna added a comment - fixed. thanks!

          People

          • Assignee:
            Unassigned
            Reporter:
            Alik Eliashberg
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development