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


Java IGuild.getName方法代码示例

本文整理汇总了Java中sx.blah.discord.handle.obj.IGuild.getName方法的典型用法代码示例。如果您正苦于以下问题:Java IGuild.getName方法的具体用法?Java IGuild.getName怎么用?Java IGuild.getName使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在sx.blah.discord.handle.obj.IGuild的用法示例。


在下文中一共展示了IGuild.getName方法的5个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: serverElement

import sx.blah.discord.handle.obj.IGuild; //导入方法依赖的package包/类
public static String serverElement(IGuild g, Account acc) {
	String s = "<table class='table_list usermod'><tr class='table_list_top'>"
			+ "<td>"+Main.lang.getLangage("tools.usermod.guild.icon")+"</td>"
			+ "<td>"+Main.lang.getLangage("tools.usermod.guild.name")+"</td>";
		if(acc.hasPerm("guildmod"))s+="<td class='usermod_gtool'>"+Main.lang.getLangage("tools.usermod.guild.tool")+"</td>";
		s+="<td class='usermod_id'>"+Main.lang.getLangage("tools.usermod.guild.id")+"</td></tr>"
			+ "\n<tr>"
			+ "\n<td class='usermod_gimg'><img src='"+g.getIconURL()+"' alt='"+Main.lang.getLangage("tools.usermod.guild.icon")+"' /></td>"
			+ "\n<td>"+g.getName()+"</td>";
		if(acc.hasPerm("guildmod")) s+="\n<td>\n <ul>"
			+ "\n  <a href='tools.ap?app=guildmod&guild="+g.getLongID()+"#text_edit'><li>"+Main.lang.getLangage("tools.guildmod.channel.text")+"</li></a>"
			+ "\n  <a href='tools.ap?app=guildmod&guild="+g.getLongID()+"#voice_edit'><li>"+Main.lang.getLangage("tools.guildmod.channel.voice")+"</li></a>"
			+ "\n  <a href='tools.ap?app=guildmod&guild="+g.getLongID()+"#role_edit'><li>"+Main.lang.getLangage("tools.guildmod.role")+"</li></a>"
			+ "\n  <a href='tools.ap?app=usermod&guild="+g.getLongID()+"#user_edit'><li>"+Main.lang.getLangage("tools.usermod")+"</li></a>"
			+ "\n </ul>\n</td>";
		s+="\n<td>"+g.getLongID()+"</td>"
			+ "\n</tr></table>";
	return s;
}
 
开发者ID:ate47,项目名称:ATEBot,代码行数:20,代码来源:UserModHandler.java

示例2: getGuild

import sx.blah.discord.handle.obj.IGuild; //导入方法依赖的package包/类
public DbGuild getGuild(IGuild guild){
    if(Karren.conf.getAllowSQLRW()){
        if(!dbGuildCache.containsKey(guild.getStringID())) {
            String sql = "INSERT IGNORE Guild (GuildID, GuildOwner, GuildName, CommandPrefix, RollDifficulty, MaxVolume, RandomRange, OverrideChannel) VALUES (?, ?, ?, null, -1, 40, 0, 0)";
            Object[] params = {guild.getStringID(), guild.getOwner().getName(), guild.getName()};
            Yank.execute(sql, params);
            sql = "SELECT * FROM Guild WHERE GuildID=?";
            Object[] params2 = {guild.getStringID()};
            DbGuild dbGuild = Yank.queryBean(sql, DbGuild.class, params2);
            dbGuildCache.put(guild.getStringID(), dbGuild);
            return dbGuild;
        } else {
            return dbGuildCache.get(guild.getStringID());
        }
    }
    return null;
}
 
开发者ID:ripxfrostbite,项目名称:karren-sama,代码行数:18,代码来源:MySQLInterface.java

示例3: fromGuild

import sx.blah.discord.handle.obj.IGuild; //导入方法依赖的package包/类
public WebGuild fromGuild(IGuild g) {
	id = g.getStringID();
	name = g.getName();
	iconUrl = g.getIconURL();
	botNick = Main.client.getOurUser().getNicknameForGuild(g);

	settings = DatabaseManager.getManager().getSettings(g.getLongID());

	//Handle lists and stuffs
	for (IRole r : g.getRoles()) {
		roles.add(new WebRole().fromRole(r, settings));
	}

	WebChannel all = new WebChannel();
	all.setId(0);
	all.setName("All Channels");
	all.setDiscalChannel(settings.getDiscalChannel().equalsIgnoreCase("all"));
	channels.add(all);
	for (IChannel c : g.getChannels()) {
		channels.add(new WebChannel().fromChannel(c, settings));
	}
	announcements.addAll(DatabaseManager.getManager().getAnnouncements(g.getLongID()));

	calendar = new WebCalendar().fromCalendar(DatabaseManager.getManager().getMainCalendar(Long.valueOf(id)), settings);

	return this;
}
 
开发者ID:NovaFox161,项目名称:DisCal-Discord-Bot,代码行数:28,代码来源:WebGuild.java

示例4: getGuild

import sx.blah.discord.handle.obj.IGuild; //导入方法依赖的package包/类
public synchronized static Guild getGuild(IGuild discordGuild, boolean forceCache){
    Guild guild = getGuilds().get(discordGuild.getStringID());

    if (guild == null && forceCache){
        guild = new Guild(discordGuild.getStringID(), discordGuild.getName(), Constants.defaultLanguage);
        guild.addToDatabase();
    }

    return guild;
}
 
开发者ID:Kaysoro,项目名称:KaellyBot,代码行数:11,代码来源:Guild.java

示例5: DiscordGuild

import sx.blah.discord.handle.obj.IGuild; //导入方法依赖的package包/类
public DiscordGuild(IGuild guild) {
    this.id = guild.getID();
    this.name = guild.getName();
}
 
开发者ID:quanticc,项目名称:ugc-bot-redux,代码行数:5,代码来源:DiscordGuild.java


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