X-Git-Url: https://gerrit.simantics.org/r/gitweb?p=simantics%2Fplatform.git;a=blobdiff_plain;f=bundles%2Forg.simantics.scenegraph%2Fsrc%2Forg%2Fsimantics%2Fscenegraph%2Fg2d%2Fevents%2Fcommand%2FCommand.java;fp=bundles%2Forg.simantics.scenegraph%2Fsrc%2Forg%2Fsimantics%2Fscenegraph%2Fg2d%2Fevents%2Fcommand%2FCommand.java;h=fc2c2e24802c6c46e1db574068000bb761023d07;hp=ee889703ba588cc140a10c735f30f911d2879913;hb=0ae2b770234dfc3cbb18bd38f324125cf0faca07;hpb=24e2b34260f219f0d1644ca7a138894980e25b14 diff --git a/bundles/org.simantics.scenegraph/src/org/simantics/scenegraph/g2d/events/command/Command.java b/bundles/org.simantics.scenegraph/src/org/simantics/scenegraph/g2d/events/command/Command.java index ee889703b..fc2c2e248 100644 --- a/bundles/org.simantics.scenegraph/src/org/simantics/scenegraph/g2d/events/command/Command.java +++ b/bundles/org.simantics.scenegraph/src/org/simantics/scenegraph/g2d/events/command/Command.java @@ -1,55 +1,55 @@ -/******************************************************************************* - * Copyright (c) 2007, 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.scenegraph.g2d.events.command; - -import java.io.Serializable; - -/** - * - * @See {@link Commands} Default commands - * @See {@link CommandKeyBinding} Default command bindings - * - * @author Toni Kalajainen - */ -public class Command implements Serializable { - - private static final long serialVersionUID = 9117246464320469783L; - - public final String id; - - public Command(String id) { - if (id == null) - throw new NullPointerException("null id"); - this.id = id; - } - - @Override - public int hashCode() { - return id.hashCode(); - } - - @Override - public boolean equals(Object obj) { - if (this == obj) - return true; - if (!(obj instanceof Command)) - return false; - Command other = (Command) obj; - return id.equals(other.id); - } - - @Override - public String toString() { - return id; - } - -} +/******************************************************************************* + * Copyright (c) 2007, 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.scenegraph.g2d.events.command; + +import java.io.Serializable; + +/** + * + * @See {@link Commands} Default commands + * @See {@link CommandKeyBinding} Default command bindings + * + * @author Toni Kalajainen + */ +public class Command implements Serializable { + + private static final long serialVersionUID = 9117246464320469783L; + + public final String id; + + public Command(String id) { + if (id == null) + throw new NullPointerException("null id"); + this.id = id; + } + + @Override + public int hashCode() { + return id.hashCode(); + } + + @Override + public boolean equals(Object obj) { + if (this == obj) + return true; + if (!(obj instanceof Command)) + return false; + Command other = (Command) obj; + return id.equals(other.id); + } + + @Override + public String toString() { + return id; + } + +}