List of usage examples for java.util Arrays deepToString
public static String deepToString(Object[] a)
From source file:org.esigate.extension.http.CustomizableDNSResolver.java
/** * {@inheritDoc}// w ww.j av a 2 s . c o m */ @Override public InetAddress[] resolve(final String host) throws UnknownHostException { InetAddress[] resolvedAddresses = dnsMap.get(host); if (LOG.isInfoEnabled()) { LOG.info("Resolving {} to {}", host, Arrays.deepToString(resolvedAddresses)); } if (resolvedAddresses == null) { resolvedAddresses = super.resolve(host); } return resolvedAddresses; }
From source file:de.kopis.glacier.parsers.GlacierUploaderOptionParserTest.java
@Test public void hasRequiredVaultOptionWithName() { final OptionSet optionSet = optionsParser.parse(args); assertTrue("Option 'vault' not found in " + Arrays.deepToString(optionSet.specs().toArray()), optionSet.has("vault")); assertEquals("Value of option 'vault' not found in " + Arrays.deepToString(optionSet.specs().toArray()), "vaultname", optionSet.valueOf("vault")); }
From source file:com.celements.pagetype.xobject.XObjectPageTypeConfig.java
public List<String> getCategories() { List<String> categories = pageType.getCategories(getContext()); if (categories.isEmpty()) { LOGGER.debug("getCategories for [" + getName() + "] empty List found returning" + " [\"\"]."); return Arrays.asList(""); } else {/*from w w w . j a va2s. c o m*/ LOGGER.debug("getCategories for [" + getName() + "] returning [" + Arrays.deepToString(categories.toArray()) + "]"); return categories; } }
From source file:bi.meteorite.pages.SaikuTable.java
public WebElement findFirstRowWhere(final BeanMatcher... matchers) { List<WebElement> rows = getRowElementsWhere(matchers); if (rows.isEmpty()) { throw new AssertionError( "Expecting a table with at least one row where: " + Arrays.deepToString(matchers)); }//from w w w . jav a2 s . c o m return rows.get(0); }
From source file:Main.java
/** * return a 2d array with the value and its count. Can deal with multiples. * Values will be in the same order as array (with subsequent duplicate * values removed). *// w w w . ja va 2s . c o m * * @param array * the array * @param verbose * the verbose * @return the count */ public static String[][] getCount(String[] array, boolean verbose) { ArrayList<String[]> countArray = new ArrayList<String[]>(); double count = 0; for (int i = 0; i < array.length; ++i) { // check if list contains current value boolean unique = true; for (String[] ia : countArray) { if (ia[0].equals(array[i])) { unique = false; } } // Count values if (unique) { count = 1; for (int j = i + 1; j < array.length; ++j) { if (array[i] == array[j]) { count++; } } countArray.add(new String[] { array[i], String.valueOf(count) }); } } // Log.d(countArray); String[][] stringArray = new String[countArray.size()][]; stringArray = countArray.toArray(stringArray); if (verbose) { System.out.println("Value and count of value:\n" + Arrays.deepToString(stringArray)); } return stringArray; }
From source file:yaphyre.geometry.Matrix.java
@Override public String toString() { return Arrays.deepToString(m); }
From source file:com.celements.migrations.CelSubSystemMigrationCoordinator.java
public void startSubSystemMigrations(XWikiContext context) throws XWikiException { if ((subSysMigrationManagerMap != null) && (subSysMigrationManagerMap.size() > 0)) { LOGGER.debug("Found [" + subSysMigrationManagerMap.size() + "] SubSystemMigrationManagers [" + subSysMigrationManagerMap.keySet() + "]."); String[] subSysMigConfig = context.getWiki().getConfig() .getPropertyAsList("celements.subsystems.migration.manager.order"); if (subSysMigConfig.length == 0) { subSysMigConfig = new String[] { "XWikiSubSystem" }; }/* w w w . j a v a 2 s . c o m*/ LOGGER.info("executing following subsystem migration manager in this order: " + Arrays.deepToString(subSysMigConfig)); for (String subSystemHintName : subSysMigConfig) { ISubSystemMigrationManager subSystemMigrationManager = subSysMigrationManagerMap .get(subSystemHintName); if ("1".equals( context.getWiki().Param("celements.subsystems." + subSystemHintName + ".migration", "0"))) { LOGGER.info("starting migration for [" + subSystemMigrationManager.getSubSystemName() + "]."); subSystemMigrationManager.startMigrations(context); LOGGER.info("finished migration for [" + subSystemMigrationManager.getSubSystemName() + "]."); } else { LOGGER.info("skipping migration for [" + subSystemHintName + "]."); } } } else { LOGGER.fatal("allSubMigrationManagers is empty. Expecting at least the" + " xwikiSubSystem migration manager. " + subSysMigrationManagerMap); } }
From source file:com.moilioncircle.redis.replicator.RedisMixReplicator.java
protected void doOpen() throws IOException { RdbParser parser = new RdbParser(inputStream, this); parser.parse();//w w w. ja v a2s.c om while (true) { Object obj = replyParser.parse(); if (obj instanceof Object[]) { if (configuration.isVerbose() && logger.isDebugEnabled()) logger.debug(Arrays.deepToString((Object[]) obj)); Object[] command = (Object[]) obj; CommandName cmdName = CommandName.name((String) command[0]); final CommandParser<? extends Command> operations; //if command do not register. ignore if ((operations = commands.get(cmdName)) == null) { logger.warn("command [" + cmdName + "] not register. raw command:[" + Arrays.deepToString((Object[]) obj) + "]"); continue; } //do command replyParser Command parsedCommand = operations.parse(command); //submit event this.submitEvent(parsedCommand); } else { logger.info("redis reply:" + obj); } } }
From source file:io.fouad.jtb.core.beans.InlineKeyboardMarkup.java
@Override public String toString() { return "InlineKeyboardMarkup{" + "inlineKeyboard=" + Arrays.deepToString(inlineKeyboard) + "}"; }
From source file:yaphyre.core.math.Matrix.java
@Override public String toString() { return MoreObjects.toStringHelper(this).add("coefficients", Arrays.deepToString(m)).toString(); }