org.apache.sis.internal.util.Utilities.toString()方法的使用及代码示例

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

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

Utilities.toString介绍

[英]Returns a string representation of an instance of the given class having the given properties. This is a convenience method for implementation of Object#toString() methods that are used mostly for debugging purpose.
[中]返回具有给定属性的给定类的实例的字符串表示形式。这是实现对象#toString()方法的一种方便方法,这些方法主要用于调试目的。

代码示例

代码示例来源:origin: apache/sis

/**
   * Returns the next value to be returned, for debugging purpose only.
   */
  @Override
  public String toString() {
    return Utilities.toString(Iter.class, "next", next);
  }
}

代码示例来源:origin: apache/sis

/**
 * Returns a string representation of this grid.
 *
 * @return a string representation for debugging purpose.
 */
@Override
public String toString() {
  return Utilities.toString(getClass(), "file", (files.length != 0) ? files[0] : null);
}

代码示例来源:origin: apache/sis

/**
 * Returns a string representation of this {@code ProbeResult} for debugging purpose.
 */
@Override
public String toString() {
  return Utilities.toString(getClass(), "isSupported", isSupported, "mimeType", mimeType, "version", version);
}

代码示例来源:origin: apache/sis

/**
   * Do not format all properties for avoiding a never-ending loop.
   */
  @Override
  public String toString() {
    return Utilities.toString(getClass(), "locale", locale, "timezone", timezone);
  }
}

代码示例来源:origin: apache/sis

/**
   * Returns a string representation of this iterator for debugging purpose.
   */
  @Override
  public String toString() {
    return org.apache.sis.internal.util.Utilities.toString(getClass(), "zone", encoder.crsZone,
        "downward", downward, "yStart", yStart, "yEnd", yEnd, "gridX", gridX, "xEnd", xEnd);
  }
}

代码示例来源:origin: org.apache.sis.core/sis-utility

/**
   * Returns the next value to be returned, for debugging purpose only.
   */
  @Debug
  @Override
  public String toString() {
    return Utilities.toString(Iter.class, "next", next);
  }
}

代码示例来源:origin: org.apache.sis.core/sis-referencing

/**
 * Returns a string representation of this grid.
 *
 * @return a string representation for debugging purpose.
 */
@Debug
@Override
public String toString() {
  return Utilities.toString(getClass(), "file", (files.length != 0) ? files[0] : null);
}

代码示例来源:origin: org.apache.sis.storage/sis-storage

/**
 * Returns a string representation of this {@code ProbeResult} for debugging purpose.
 */
@Debug
@Override
public String toString() {
  return Utilities.toString(getClass(), "isSupported", isSupported, "mimeType", mimeType, "version", version);
}

代码示例来源:origin: apache/sis

/**
 * Returns a string representation for debugging purpose.
 */
@Override
public String toString() {
  return Utilities.toString(getClass(),
      "view",       Classes.getShortClassName(view),
      "wrapperFor", (wrapperFor != null) ? Classes.getShortClassName(wrapperFor.view) : null,
      "cascade",    cascade,
      "isValid",    isValid);
}

代码示例来源:origin: org.apache.sis.storage/sis-storage

/**
 * Returns a string representation for debugging purpose.
 */
@Debug
@Override
public String toString() {
  return Utilities.toString(getClass(),
      "view",       Classes.getShortClassName(view),
      "wrapperFor", (wrapperFor != null) ? Classes.getShortClassName(wrapperFor.view) : null,
      "cascade",    cascade,
      "isValid",    isValid);
}

代码示例来源:origin: apache/sis

/**
 * Tests the {@link Utilities#toString(Class, Object[])} method.
 */
@Test
public void testToString() {
  assertEquals("Number[base=“decimal”, value=20]", Utilities.toString(Number.class, "base", "decimal", "value", 20));
}

相关文章