当前位置: 首页>>代码示例>>Java>>正文


Java HashUtils类代码示例

本文整理汇总了Java中com.google.samples.apps.iosched.util.HashUtils的典型用法代码示例。如果您正苦于以下问题:Java HashUtils类的具体用法?Java HashUtils怎么用?Java HashUtils使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。


HashUtils类属于com.google.samples.apps.iosched.util包,在下文中一共展示了HashUtils类的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: getImportHashcode

import com.google.samples.apps.iosched.util.HashUtils; //导入依赖的package包/类
public String getImportHashcode() {
    StringBuilder sb = new StringBuilder();
    sb.append("id").append(id == null ? "" : id)
            .append("year").append(year)
            .append("title").append(title == null ? "" : title)
            .append("desc").append(desc == null ? "" : desc)
            .append("vid").append(vid == null ? "" : vid)
            .append("topic").append(topic == null ? "" : topic)
            .append("speakers").append(speakers == null ? "" : speakers)
            .append("thumbnailUrl").append(thumbnailUrl == null ? "" : thumbnailUrl);
    return HashUtils.computeWeakHash(sb.toString());
}
 
开发者ID:dreaminglion,项目名称:iosched-reader,代码行数:13,代码来源:Video.java

示例2: getImportHashcode

import com.google.samples.apps.iosched.util.HashUtils; //导入依赖的package包/类
public String getImportHashcode() {
    StringBuilder sb = new StringBuilder();
    sb.append("id").append(id == null ? "" : id)
            .append("publicPlusId").append(publicPlusId == null ? "" : publicPlusId)
            .append("bio").append(bio == null ? "" : bio)
            .append("name").append(name == null ? "" : name)
            .append("company").append(company== null ? "" : company)
            .append("plusoneUrl").append(plusoneUrl == null ? "" : plusoneUrl)
            .append("twitterUrl").append(twitterUrl == null ? "" : twitterUrl)
            .append("thumbnailUrl").append(thumbnailUrl == null ? "" : thumbnailUrl);
    return HashUtils.computeWeakHash(sb.toString());
}
 
开发者ID:dreaminglion,项目名称:iosched-reader,代码行数:13,代码来源:Speaker.java

示例3: getImportHashCode

import com.google.samples.apps.iosched.util.HashUtils; //导入依赖的package包/类
public String getImportHashCode() {
    StringBuilder sb = new StringBuilder();
    sb.append("id").append(id == null ? "" : id)
            .append("description").append(description == null ? "" : description)
            .append("title").append(title == null ? "" : title)
            .append("url").append(url == null ? "" : url)
            .append("startTimestamp").append(startTimestamp == null ? "" : startTimestamp)
            .append("endTimestamp").append(endTimestamp == null ? "" : endTimestamp)
            .append("youtubeUrl").append(youtubeUrl == null ? "" : youtubeUrl)
            .append("subtype").append(subtype == null ? "" : subtype)
            .append("room").append(room == null ? "" : room)
            .append("hashtag").append(hashtag == null ? "" : hashtag)
            .append("isLivestream").append(isLivestream ? "true" : "false")
            .append("mainTag").append(mainTag)
            .append("captionsUrl").append(captionsUrl)
            .append("photoUrl").append(photoUrl)
            .append("relatedContent").append(relatedContent)
            .append("color").append(color)
            .append("groupingOrder").append(groupingOrder);
    for (String tag : tags) {
        sb.append("tag").append(tag);
    }
    for (String speaker : speakers) {
        sb.append("speaker").append(speaker);
    }
    return HashUtils.computeWeakHash(sb.toString());
}
 
开发者ID:gdg-bh,项目名称:AppDevFestSudeste2015,代码行数:28,代码来源:Session.java

示例4: getImportHashCode

import com.google.samples.apps.iosched.util.HashUtils; //导入依赖的package包/类
public String getImportHashCode() {
    StringBuilder sb = new StringBuilder();
    sb.append("id").append(id == null ? "" : id)
            .append("plusId").append(plusId == null ? "" : plusId)
            .append("bio").append(bio == null ? "" : bio)
            .append("name").append(name == null ? "" : name)
            .append("title").append(title == null ? "" : title)
            .append("url").append(url == null ? "" : url)
            .append("imageUrl").append(imageUrl == null ? "" : imageUrl)
            .append("country").append(country == null ? "" : country)
            .append("city").append(city == null ? "" : city)
            .append("attending").append(attending);
    return HashUtils.computeWeakHash(sb.toString());
}
 
开发者ID:gdg-bh,项目名称:AppDevFestSudeste2015,代码行数:15,代码来源:Expert.java

示例5: getImportHashcode

import com.google.samples.apps.iosched.util.HashUtils; //导入依赖的package包/类
public String getImportHashcode() {
    StringBuilder sb = new StringBuilder();
    sb.append("id").append(id == null ? "" : id)
            .append("publicPlusId").append(publicPlusId == null ? "" : publicPlusId)
            .append("bio").append(bio == null ? "" : bio)
            .append("name").append(name == null ? "" : name)
            .append("company").append(company== null ? "" : company)
            .append("plusoneUrl").append(plusoneUrl == null ? "" : plusoneUrl)
            .append("thumbnailUrl").append(thumbnailUrl == null ? "" : thumbnailUrl);
    return HashUtils.computeWeakHash(sb.toString());
}
 
开发者ID:gdg-bh,项目名称:AppDevFestSudeste2015,代码行数:12,代码来源:Speaker.java

示例6: getCacheKey

import com.google.samples.apps.iosched.util.HashUtils; //导入依赖的package包/类
/**
 * Returns the cache key to be used to store the given URL. The cache key is the
 * file name under which the contents of the URL are stored.
 * @param url The URL.
 * @return The cache key (guaranteed to be a valid filename)
 */
private String getCacheKey(String url) {
    return HashUtils.computeWeakHash(url.trim()) + String.format("%04x", url.length());
}
 
开发者ID:dreaminglion,项目名称:iosched-reader,代码行数:10,代码来源:RemoteConferenceDataFetcher.java

示例7: getCacheKey

import com.google.samples.apps.iosched.util.HashUtils; //导入依赖的package包/类
/**
 * Returns the cache key to be used to store the given URL. The cache key is the file name under
 * which the contents of the URL are stored.
 *
 * @param url The URL.
 * @return The cache key (guaranteed to be a valid filename)
 */
private String getCacheKey(String url) {
    return HashUtils.computeWeakHash(url.trim()) + String.format("%04x", url.length());
}
 
开发者ID:google,项目名称:iosched,代码行数:11,代码来源:RemoteConferenceDataFetcher.java


注:本文中的com.google.samples.apps.iosched.util.HashUtils类示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。