com.google.gwt.dev.util.Util.computeStrongName()方法的使用及代码示例

x33g5p2x  于2022-02-01 转载在 其他  
字(7.1k)|赞(0)|评价(0)|浏览(164)

本文整理了Java中com.google.gwt.dev.util.Util.computeStrongName()方法的一些代码示例,展示了Util.computeStrongName()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Util.computeStrongName()方法的具体详情如下:
包路径:com.google.gwt.dev.util.Util
类名称:Util
方法名:computeStrongName

Util.computeStrongName介绍

暂无

代码示例

代码示例来源:origin: com.google.gwt/gwt-servlet

private String getMd5HashOfData() {
 return Util.computeStrongName(Util.getBytes(data.toString()));
}

代码示例来源:origin: com.google.gwt/gwt-servlet

private static String key(ImageResourceDeclaration image, URL url) {
 return Util.computeStrongName(Util.readURLAsBytes(url)) + ":"
   + image.getScaleHeight() + ":" + image.getScaleWidth();
}

代码示例来源:origin: com.vaadin.external.gwt/gwt-user

private String getMd5HashOfData() {
 return Util.computeStrongName(Util.getBytes(data.toString()));
}

代码示例来源:origin: net.wetheinter/gwt-user

private String getMd5HashOfData() {
 return Util.computeStrongName(Util.getBytes(data.toString()));
}

代码示例来源:origin: net.wetheinter/gwt-user

boolean forceExternal) throws UnableToCompleteException {
String strongName = Util.computeStrongName(data);
String toReturn = strongNameToExpressions.get(strongName);
if (toReturn != null) {

代码示例来源:origin: com.vaadin.external.gwt/gwt-user

boolean forceExternal) throws UnableToCompleteException {
String strongName = Util.computeStrongName(data);
String toReturn = strongNameToExpressions.get(strongName);
if (toReturn != null) {

代码示例来源:origin: net.wetheinter/gwt-user

@Override
protected void doCreateBundleForPermutation(TreeLogger logger,
  GeneratorContext generatorContext, FieldsImpl fields,
  String generatedSimpleSourceName) throws UnableToCompleteException {
 String partialPath = Util.computeStrongName(Util.getBytes(generatedSimpleSourceName))
   + BUNDLE_EXTENSION;
 resourceContext.setPartialPath(partialPath);
 fields.setInitializer(bundleBaseIdent,
   "\"mhtml:\" + GWT.getModuleBaseURL() + \"" + partialPath + "!cid:\"");
}

代码示例来源:origin: com.vaadin.external.gwt/gwt-user

@Override
protected void doCreateBundleForPermutation(TreeLogger logger,
  GeneratorContext generatorContext, FieldsImpl fields,
  String generatedSimpleSourceName) throws UnableToCompleteException {
 String partialPath = Util.computeStrongName(Util.getBytes(generatedSimpleSourceName))
   + BUNDLE_EXTENSION;
 resourceContext.setPartialPath(partialPath);
 fields.setInitializer(bundleBaseIdent,
   "\"mhtml:\" + GWT.getModuleBaseURL() + \"" + partialPath + "!cid:\"");
}

代码示例来源:origin: net.wetheinter/gwt-user

private static String key(ImageResourceDeclaration image, URL url) {
 return Util.computeStrongName(Util.readURLAsBytes(url)) + ":"
   + image.getScaleHeight() + ":" + image.getScaleWidth();
}

代码示例来源:origin: com.vaadin.external.gwt/gwt-user

private static String key(ImageResourceDeclaration image, URL url) {
 return Util.computeStrongName(Util.readURLAsBytes(url)) + ":"
   + image.getScaleHeight() + ":" + image.getScaleWidth();
}

代码示例来源:origin: com.vaadin.external.gwt/gwt-user

private void emitPolicyFileArtifact(TreeLogger logger, GeneratorContext context,
  String partialPath) throws UnableToCompleteException {
 try {
  String qualifiedSourceName = serviceIntf.getQualifiedSourceName();
  ByteArrayOutputStream baos = new ByteArrayOutputStream();
  Writer writer;
  writer =
    new OutputStreamWriter(baos, SerializationPolicyLoader.SERIALIZATION_POLICY_FILE_ENCODING);
  writer.write("serviceClass: " + qualifiedSourceName + "\n");
  writer.write("path: " + partialPath + "\n");
  writer.close();
  byte[] manifestBytes = baos.toByteArray();
  String md5 = Util.computeStrongName(manifestBytes);
  OutputStream os =
    context.tryCreateResource(logger, MANIFEST_ARTIFACT_DIR + "/" + md5 + ".txt");
  os.write(manifestBytes);
  GeneratedResource resource = context.commitResource(logger, os);
  // TODO: change to Deploy when possible
  resource.setVisibility(Visibility.LegacyDeploy);
 } catch (UnsupportedEncodingException e) {
  logger.log(TreeLogger.ERROR, SerializationPolicyLoader.SERIALIZATION_POLICY_FILE_ENCODING
    + " is not supported", e);
  throw new UnableToCompleteException();
 } catch (IOException e) {
  logger.log(TreeLogger.ERROR, null, e);
  throw new UnableToCompleteException();
 }
}

代码示例来源:origin: seanchenxi/gwt-storage

private void emitPolicyFileArtifact(TreeLogger logger, GeneratorContext context,
                   String partialPath) throws UnableToCompleteException {
  try {
   String qualifiedSourceName = serializerType.getQualifiedSourceName();
   ByteArrayOutputStream baos = new ByteArrayOutputStream();
   Writer writer;
   writer = new OutputStreamWriter(baos, SerializationPolicyLoader.SERIALIZATION_POLICY_FILE_ENCODING);
   writer.write("serviceClass: " + qualifiedSourceName + "\n");
   writer.write("path: " + partialPath + "\n");
   writer.close();

   byte[] manifestBytes = baos.toByteArray();
   String md5 = Util.computeStrongName(manifestBytes);
   OutputStream os =
       context.tryCreateResource(logger, ProxyCreator.MANIFEST_ARTIFACT_DIR + "/" + md5 + ".txt");
   os.write(manifestBytes);

   GeneratedResource resource = context.commitResource(logger, os);
   // TODO: change to Deploy when possible
   resource.setVisibility(EmittedArtifact.Visibility.LegacyDeploy);
  } catch (UnsupportedEncodingException e) {
   logger.log(TreeLogger.ERROR, SerializationPolicyLoader.SERIALIZATION_POLICY_FILE_ENCODING + " is not supported", e);
   throw new UnableToCompleteException();
  } catch (IOException e) {
   logger.log(TreeLogger.ERROR, null, e);
   throw new UnableToCompleteException();
  }
 }
}

代码示例来源:origin: net.wetheinter/gwt-user

private void emitPolicyFileArtifact(TreeLogger logger, GeneratorContext context,
  String partialPath) throws UnableToCompleteException {
 try {
  String qualifiedSourceName = serviceIntf.getQualifiedSourceName();
  ByteArrayOutputStream baos = new ByteArrayOutputStream();
  Writer writer;
  writer =
    new OutputStreamWriter(baos, SerializationPolicyLoader.SERIALIZATION_POLICY_FILE_ENCODING);
  writer.write("serviceClass: " + qualifiedSourceName + "\n");
  writer.write("path: " + partialPath + "\n");
  writer.close();
  byte[] manifestBytes = baos.toByteArray();
  String md5 = Util.computeStrongName(manifestBytes);
  OutputStream os =
    context.tryCreateResource(logger, MANIFEST_ARTIFACT_DIR + "/" + md5 + ".txt");
  os.write(manifestBytes);
  GeneratedResource resource = context.commitResource(logger, os);
  // TODO: change to Deploy when possible
  resource.setVisibility(Visibility.LegacyDeploy);
 } catch (UnsupportedEncodingException e) {
  logger.log(TreeLogger.ERROR, SerializationPolicyLoader.SERIALIZATION_POLICY_FILE_ENCODING
    + " is not supported", e);
  throw new UnableToCompleteException();
 } catch (IOException e) {
  logger.log(TreeLogger.ERROR, null, e);
  throw new UnableToCompleteException();
 }
}

代码示例来源:origin: net.wetheinter/gwt-user

String serializationPolicyName = Util.computeStrongName(serializationPolicyFileContents);

代码示例来源:origin: com.vaadin.external.gwt/gwt-user

String serializationPolicyName = Util.computeStrongName(serializationPolicyFileContents);

代码示例来源:origin: com.vaadin.external.gwt/gwt-user

String bundleFileName = Util.computeStrongName(imageBytes) + ".cache."
  + BUNDLE_FILE_TYPE;

代码示例来源:origin: net.wetheinter/gwt-user

String bundleFileName = Util.computeStrongName(imageBytes) + ".cache."
  + BUNDLE_FILE_TYPE;

代码示例来源:origin: com.vaadin.external.gwt/gwt-user

String strongName = Util.computeStrongName(data);

代码示例来源:origin: net.wetheinter/gwt-user

String strongName = Util.computeStrongName(data);

相关文章