X-Git-Url: https://gerrit.simantics.org/r/gitweb?a=blobdiff_plain;f=bundles%2Forg.simantics.databoard%2Fsrc%2Forg%2Fsimantics%2Fdataboard%2Futil%2FObjectUtils.java;h=85b8af1539521e17b69f9e9fc2e541348742afb6;hb=c69064f9e740eb4abe8448a63d306a085e036e1c;hp=f360b25ecaa321ae5be8253fe77e1df0eaabbc81;hpb=873afce76b92cb7cf9094fe60e407278f220e5ed;p=simantics%2Fplatform.git diff --git a/bundles/org.simantics.databoard/src/org/simantics/databoard/util/ObjectUtils.java b/bundles/org.simantics.databoard/src/org/simantics/databoard/util/ObjectUtils.java index f360b25ec..85b8af153 100644 --- a/bundles/org.simantics.databoard/src/org/simantics/databoard/util/ObjectUtils.java +++ b/bundles/org.simantics.databoard/src/org/simantics/databoard/util/ObjectUtils.java @@ -1,25 +1,25 @@ -/******************************************************************************* - * Copyright (c) 2010 Association for Decentralized Information Management in - * Industry THTH ry. - * All rights reserved. This program and the accompanying materials - * are made available under the terms of the Eclipse Public License v1.0 - * which accompanies this distribution, and is available at - * http://www.eclipse.org/legal/epl-v10.html - * - * Contributors: - * VTT Technical Research Centre of Finland - initial API and implementation - *******************************************************************************/ +/******************************************************************************* + * Copyright (c) 2010 Association for Decentralized Information Management in + * Industry THTH ry. + * All rights reserved. This program and the accompanying materials + * are made available under the terms of the Eclipse Public License v1.0 + * which accompanies this distribution, and is available at + * http://www.eclipse.org/legal/epl-v10.html + * + * Contributors: + * VTT Technical Research Centre of Finland - initial API and implementation + *******************************************************************************/ package org.simantics.databoard.util; -import java.lang.reflect.Array; -import java.lang.reflect.Field; -import java.util.Arrays; -import java.util.Collection; -import java.util.HashSet; -import java.util.Iterator; -import java.util.Objects; -import java.util.Set; +import java.lang.reflect.Array; +import java.lang.reflect.Field; +import java.util.Arrays; +import java.util.Collection; +import java.util.HashSet; +import java.util.Iterator; +import java.util.Objects; +import java.util.Set; /** * ObjectUtils @@ -38,8 +38,8 @@ public class ObjectUtils { public static boolean objectEquals(Object o1, Object o2) { if (o1==o2) return true; if (o1==null && o2==null) return true; - if (o1==null || o2==null) return false; - if (o1.getClass().isArray() && o2.getClass().isArray()) + if (o1==null || o2==null) return false; + if (o1.getClass().isArray() && o2.getClass().isArray()) return Objects.deepEquals(o1, o2); return o1.equals(o2); }