Tabnine Logo
SoaHeader.getCallerFrom
Code IndexAdd Tabnine to your IDE (free)

How to use
getCallerFrom
method
in
com.isuwang.dapeng.core.SoaHeader

Best Java code snippets using com.isuwang.dapeng.core.SoaHeader.getCallerFrom (Showing top 7 results out of 315)

origin: isuwang/isuwang-soa

public Task(TransactionContext context) {
  this.startTime = System.currentTimeMillis();
  this.seqid = context.getSeqid();
  SoaHeader soaHeader = context.getHeader();
  this.serviceName = soaHeader.getServiceName();
  this.versionName = soaHeader.getVersionName();
  this.methodName = soaHeader.getMethodName();
  this.callerFrom = soaHeader.getCallerFrom().isPresent() ? soaHeader.getCallerFrom().get() : null;
  this.callerIp = soaHeader.getCallerIp().isPresent() ? soaHeader.getCallerIp().get() : null;
  this.operatorId = soaHeader.getOperatorId().isPresent() ? soaHeader.getOperatorId().get() : null;
  this.operatorName = soaHeader.getOperatorName().isPresent() ? soaHeader.getOperatorName().get() : null;
  this.customerId = soaHeader.getCustomerId().isPresent() ? soaHeader.getCustomerId().get() : null;
  this.customerName = soaHeader.getCustomerName().isPresent() ? soaHeader.getCustomerName().get() : null;
  this.currentThread = Thread.currentThread();
}
origin: isuwang/isuwang-soa

/**
 * 根据matcher.Id,返回上下文中对应的值
 *
 * @param ctx
 * @param matcher
 * @return
 */
public static Object checkFieldMatcher(InvocationContext ctx, Matcher matcher) {
  Id id = matcher.getId();
  if ("operatorId".equals(id.getName())) {
    return ctx.getHeader().getOperatorId().orElse(null);
  } else if ("callerFrom".equals(id.getName())) {
    return ctx.getHeader().getCallerFrom().orElse(null);
  } else if ("ip".equals(id.getName())) {
    return ctx.getHeader().getCallerIp().orElse(null);
  } else if ("customerId".equals(id.getName())) {
    return ctx.getHeader().getCustomerId().orElse(null);
  } else if ("service".equals(id.getName())) {
    return ctx.getHeader().getServiceName();
  } else if ("method".equals(id.getName())) {
    return ctx.getHeader().getMethodName();
  } else if ("version".equals(id.getName())) {
    return ctx.getHeader().getVersionName();
  } else {
    throw new AssertionError("not support Field: " + id.getName());
  }
}
origin: com.isuwang/dapeng-route-impl

/**
 * 根据matcher.Id,返回上下文中对应的值
 *
 * @param ctx
 * @param matcher
 * @return
 */
public static Object checkFieldMatcher(InvocationContext ctx, Matcher matcher) {
  Id id = matcher.getId();
  if ("operatorId".equals(id.getName())) {
    return ctx.getHeader().getOperatorId().orElse(null);
  } else if ("callerFrom".equals(id.getName())) {
    return ctx.getHeader().getCallerFrom().orElse(null);
  } else if ("ip".equals(id.getName())) {
    return ctx.getHeader().getCallerIp().orElse(null);
  } else if ("customerId".equals(id.getName())) {
    return ctx.getHeader().getCustomerId().orElse(null);
  } else if ("service".equals(id.getName())) {
    return ctx.getHeader().getServiceName();
  } else if ("method".equals(id.getName())) {
    return ctx.getHeader().getMethodName();
  } else if ("version".equals(id.getName())) {
    return ctx.getHeader().getVersionName();
  } else {
    throw new AssertionError("not support Field: " + id.getName());
  }
}
origin: com.isuwang/dapeng-remoting-api

soaHeader.setVersionName(versionName);
if (!soaHeader.getCallerFrom().isPresent())
  soaHeader.setCallerFrom(Optional.of(SoaSystemEnvProperties.SOA_SERVICE_CALLERFROM));
origin: isuwang/isuwang-soa

soaHeader.setVersionName(versionName);
if (!soaHeader.getCallerFrom().isPresent())
  soaHeader.setCallerFrom(Optional.of(SoaSystemEnvProperties.SOA_SERVICE_CALLERFROM));
origin: isuwang/isuwang-soa

  oprot.writeFieldEnd();
if (bean.getCallerFrom().isPresent()) {
  oprot.writeFieldBegin(new TField("callerFrom", TType.STRING, (short) 4));
  oprot.writeString(bean.getCallerFrom().get());
  oprot.writeFieldEnd();
origin: com.isuwang/dapeng-core

  oprot.writeFieldEnd();
if (bean.getCallerFrom().isPresent()) {
  oprot.writeFieldBegin(new TField("callerFrom", TType.STRING, (short) 4));
  oprot.writeString(bean.getCallerFrom().get());
  oprot.writeFieldEnd();
com.isuwang.dapeng.coreSoaHeadergetCallerFrom

Popular methods of SoaHeader

  • getMethodName
  • getServiceName
  • getVersionName
  • <init>
  • setMethodName
  • setServiceName
  • setVersionName
  • getRespCode
  • setCallerFrom
  • getCustomerId
  • getOperatorId
  • getRespMessage
  • getOperatorId,
  • getRespMessage,
  • getCallerIp,
  • getCustomerName,
  • getOperatorName,
  • setCallerIp,
  • setOperatorId,
  • setOperatorName,
  • setTransactionId

Popular in Java

  • Creating JSON documents from java classes using gson
  • getSupportFragmentManager (FragmentActivity)
  • startActivity (Activity)
  • getSystemService (Context)
  • Table (com.google.common.collect)
    A collection that associates an ordered pair of keys, called a row key and a column key, with a sing
  • KeyStore (java.security)
    KeyStore is responsible for maintaining cryptographic keys and their owners. The type of the syste
  • Pattern (java.util.regex)
    Patterns are compiled regular expressions. In many cases, convenience methods such as String#matches
  • Cipher (javax.crypto)
    This class provides access to implementations of cryptographic ciphers for encryption and decryption
  • ServletException (javax.servlet)
    Defines a general exception a servlet can throw when it encounters difficulty.
  • JTextField (javax.swing)
  • CodeWhisperer alternatives
Tabnine Logo
  • Products

    Search for Java codeSearch for JavaScript code
  • IDE Plugins

    IntelliJ IDEAWebStormVisual StudioAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimGoLandRubyMineEmacsJupyter NotebookJupyter LabRiderDataGripAppCode
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogTabnine AcademyTerms of usePrivacy policyJava Code IndexJavascript Code Index
Get Tabnine for your IDE now