java.lang.Object
co.ecg.alpaca.core.broadworks.framework.Tags

public class Tags extends Object
Performs String replacement using BroadWorks tags.
Version:
$Id: $Id
Author:
Matthew Keathley on 10/29/15
  • Constructor Details

    • Tags

      public Tags()
  • Method Details

    • replaceUserString

      public static String replaceUserString(String string, User user)
      Replacement method for BroadWorks User Tags
      Parameters:
      string - The String that contains the tags that will be replaced
      user - The User that has the tags that will be replaced.
      Returns:
      Returns a string with all the tags replaced with their values.
    • replaceDeviceString

      public static String replaceDeviceString(String string, AccessDevice accessDevice) throws HelperException
      Replacement Method for Typical BroadWorks Device Flags
      Parameters:
      string - The String that contains the tags that will be replaced
      accessDevice - The AccessDevice that has the tags that will be replaced.
      Returns:
      Returns a string with all the tags replaced with their values.
      Throws:
      HelperException - if any.
    • getTagMatcher

      public static Matcher getTagMatcher(String string)
      Creates a Matcher for the given String using the BroadWorks style tag pattern.
      Parameters:
      string - The string to create the matcher with.
      Returns:
      The Matcher using the tag pattern.
    • replaceTagString

      public static String replaceTagString(String string, Map<String,String> tagMap)
      Replacement Method for BroadWorks Tags
      Parameters:
      string - The String that contains the tags that will be replaced
      tagMap - The map of tags to their replacement values.
      Returns:
      Returns a string with all the tags replaced with their values.
    • getAccessDeviceTagMap

      public static Map<String,String> getAccessDeviceTagMap(AccessDevice accessDevice) throws HelperException

      getAccessDeviceTagMap.

      Parameters:
      accessDevice - a AccessDevice object.
      Returns:
      a Map object.
      Throws:
      HelperException - if any.
    • getUserTagMap

      public static Map<String,String> getUserTagMap(User user)

      getUserTagMap.

      Parameters:
      user - a User object.
      Returns:
      a Map object.