Loading
Get Started with Communications, Media, and Energy & Utilities (CME)...
Table of Contents
Select Filters

          No results
          No results
          Here are some search tips

          Check the spelling of your keywords.
          Use more general search terms.
          Select fewer filters to broaden your search.

          Search all of Salesforce Help
          ContextService

          ContextService

          Set the current user context so rules can be evaluated based on the current value of the context dimensions.

          Interface

          VlocityOpenInterface

          Sample Code

          Map<String, Object> inputMap = new Map<String, Object> ();
          Map<String, Object> outputMap = new Map<String, Object> ();
          Map<String, Object> optionsMap = new Map<String, Object> ();
          Map<String, Object> argsMap = new Map<String, Object> ();
          optionsMap.put(EventMessage.EVENT_NAME, 'pushevent');
          optionsMap.put(EventMessage.EVENT_TYPE, 'Context');
          String userId = u1.Id;
          argsMap.put(EventMessage.EVENT_CTX_KEY, userId);
          argsMap.put(EventMessage.EVENT_SCOPE, 'Context');
          argsMap.put(EventMessage.EVENT_STAGE, 'Pricing');
          argsMap.put('ObjectId', u1.Id);
          inputMap.put(EventMessage.EVENT_ARGS, argsMap);
          Test.startTest();
          Type t = Type.forName('ContextService');
          VlocityOpenInterface vpsi = (VlocityOpenInterface)t.newInstance();
          vpsi.invokeMethod(mthName, inputMap, outputMap, optionsMap);

          Related Implementations

          None

           
          Loading
          Salesforce Help | Article