cesiumlanguagewriter.YearMonthDay.equalsType()方法的使用及代码示例

x33g5p2x  于2022-02-05 转载在 其他  
字(3.0k)|赞(0)|评价(0)|浏览(104)

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

YearMonthDay.equalsType介绍

[英]Indicates whether another instance of this type is exactly equal to this instance.
[中]指示此类型的另一个实例是否与此实例完全相同。

代码示例

代码示例来源:origin: AnalyticalGraphicsInc/czml-writer

  1. /**
  2. *
  3. Indicates whether another object is exactly equal to this instance.
  4. * @param obj The object to compare to this instance.
  5. * @return {@code true} if {@code obj} is an instance of this type and represents the same value as this instance; otherwise, {@code false}.
  6. */
  7. @Override
  8. public boolean equals(Object obj) {
  9. return obj instanceof YearMonthDay && equalsType((YearMonthDay) obj);
  10. }

代码示例来源:origin: AnalyticalGraphicsInc/czml-writer

  1. /**
  2. *
  3. Returns {@code true} if the two instances are exactly equal.
  4. * @param left The instance to compare to {@code right}.
  5. * @param right The instance to compare to {@code left}.
  6. * @return
  7. {@code true} if {@code left} represents the same value as {@code right}; otherwise, {@code false}.
  8. */
  9. @CS2JInfo("This method implements the functionality of the overloaded operator: 'System.Boolean ==(YearMonthDay,YearMonthDay)'")
  10. public static boolean equals(@Nonnull YearMonthDay left, @Nonnull YearMonthDay right) {
  11. return left.equalsType(right);
  12. }

代码示例来源:origin: AnalyticalGraphicsInc/czml-writer

  1. /**
  2. *
  3. Returns {@code true} if the two instances are not exactly equal.
  4. * @param left The instance to compare to {@code right}.
  5. * @param right The instance to compare to {@code left}.
  6. * @return
  7. {@code true} if {@code left} does not represent the same value as {@code right}; otherwise, {@code false}.
  8. */
  9. @CS2JInfo("This method implements the functionality of the overloaded operator: 'System.Boolean !=(YearMonthDay,YearMonthDay)'")
  10. public static boolean notEquals(@Nonnull YearMonthDay left, @Nonnull YearMonthDay right) {
  11. return !left.equalsType(right);
  12. }

代码示例来源:origin: AnalyticalGraphicsInc/czml-writer

  1. YearMonthDay second = new YearMonthDay(2000, 1, 1);
  2. AssertHelper.assertEquals(first, second);
  3. Assert.assertTrue(first.equalsType(second));
  4. Assert.assertTrue(second.equalsType(first));
  5. Assert.assertEquals((int) 0, (int) first.compareTo(second));
  6. Assert.assertEquals((int) 0, (int) second.compareTo(first));
  7. second = new YearMonthDay(2001, 1, 1);
  8. AssertHelper.assertNotEqual(first, second);
  9. Assert.assertFalse(first.equalsType(second));
  10. Assert.assertFalse(second.equalsType(first));
  11. AssertHelper.assertNotEqual(0, first.compareTo(second));
  12. AssertHelper.assertNotEqual(0, second.compareTo(first));
  13. second = new YearMonthDay(2000, 2, 1);
  14. AssertHelper.assertNotEqual(first, second);
  15. Assert.assertFalse(first.equalsType(second));
  16. Assert.assertFalse(second.equalsType(first));
  17. AssertHelper.assertNotEqual(0, first.compareTo(second));
  18. AssertHelper.assertNotEqual(0, second.compareTo(first));
  19. second = new YearMonthDay(2000, 1, 2);
  20. AssertHelper.assertNotEqual(first, second);
  21. Assert.assertFalse(first.equalsType(second));
  22. Assert.assertFalse(second.equalsType(first));
  23. AssertHelper.assertNotEqual(0, first.compareTo(second));
  24. AssertHelper.assertNotEqual(0, second.compareTo(first));

相关文章