Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
 package org.drools.workbench.screens.globals.model;
 
 import java.util.List;
 
 import  org.drools.workbench.models.datamodel.packages.HasPackageName;
 import  org.jboss.errai.common.client.api.annotations.Portable;
 import  org.uberfire.commons.validation.PortablePreconditions;

The model for Globals
@Portable
public class GlobalsModel implements HasPackageName {
    private String packageName;
    private List<Globalglobals = new ArrayList<Global>();
    public List<GlobalgetGlobals() {
        return ;
    }
    public void setGlobalsfinal List<Globalglobals ) {
        this. = PortablePreconditions.checkNotNull( "globals",
                                                           globals );
    }
    @Override
    public String getPackageName() {
        return this.;
    }
    @Override
    public void setPackageNamefinal String packageName ) {
        this. = PortablePreconditions.checkNotNull( "packageName",
                                                               packageName );
    }
    @Override
    public boolean equalsObject o ) {
        if ( this == o ) {
            return true;
        }
        if ( !( o instanceof GlobalsModel ) ) {
            return false;
        }
        GlobalsModel that = (GlobalsModelo;
        if ( !.equalsthat.globals ) ) {
            return false;
        }
        if (  != null ? !.equalsthat.packageName ) : that.packageName != null ) {
            return false;
        }
        return true;
    }
    @Override
    public int hashCode() {
        int result =  != null ? .hashCode() : 0;
        result = 31 * result + .hashCode();
        return result;
    }
New to GrepCode? Check out our FAQ X