Start line:  
End line:  

Snippet Preview

Snippet HTML Code

Stack Overflow Questions
  // =================== DO NOT EDIT THIS FILE ====================
  // Generated by Modello 1.7,
  // any modifications will be overwritten.
  // ==============================================================
  
  package org.sonatype.nexus.plugins.capabilities.internal.config.persistence;

A defined capability.

Version:
$Revision$ $Date$
 
 @SuppressWarnings"all" )
 public class CCapability
     implements java.io.Serializablejava.lang.Cloneable
 {
 
       //--------------------------/
      //- Class/Member Variables -/
     //--------------------------/
 
    
The version of capability properties.
 
     private int version = 0;

    
The id of the capability.
 
     private String id;

    
Optional (user) notes about capability.
 
     private String notes;

    
The flag determining if the capability is enabled.
 
     private boolean enabled = true;

    
The type id of the capability.
 
     private String typeId;

    
Field properties.
 
 
 
       //-----------/
      //- Methods -/
     //-----------/
 
    
Method addProperty.

Parameters:
cCapabilityProperty
 
     public void addPropertyCCapabilityProperty cCapabilityProperty )
     {
         getProperties().addcCapabilityProperty );
     } //-- void addProperty( CCapabilityProperty )
 
    
Method clone.

Returns:
CCapability
 
     public CCapability clone()
     {
         try
         {
             CCapability copy = (CCapabilitysuper.clone();
 
             if ( this. != null )
             {
                 copy.properties = new java.util.ArrayList<CCapabilityProperty>();
                 for ( CCapabilityProperty item : this. )
                 {
                     copy.properties.add( ( (CCapabilityPropertyitem).clone() );
                 }
             }
 
             return copy;
         }
         catch ( java.lang.Exception ex )
         {
             throw (java.lang.RuntimeExceptionnew java.lang.UnsupportedOperationExceptiongetClass().getName()
                 + " does not support clone()" ).initCauseex );
         }
     } //-- CCapability clone()
 
    
Get the id of the capability.

Returns:
String
    public String getId()
    {
        return this.;
    } //-- String getId()

    
Get optional (user) notes about capability.

Returns:
String
    public String getNotes()
    {
        return this.;
    } //-- String getNotes()

    
Method getProperties.

Returns:
List
    {
        if ( this. == null )
        {
            this. = new java.util.ArrayList<CCapabilityProperty>();
        }
        return this.;
    } //-- java.util.List<CCapabilityProperty> getProperties()

    
Get the type id of the capability.

Returns:
String
    public String getTypeId()
    {
        return this.;
    } //-- String getTypeId()

    
Get the version of capability properties.

Returns:
int
    public int getVersion()
    {
        return this.;
    } //-- int getVersion()

    
Get the flag determining if the capability is enabled.

Returns:
boolean
    public boolean isEnabled()
    {
        return this.;
    } //-- boolean isEnabled()

    
Method removeProperty.

Parameters:
cCapabilityProperty
    public void removePropertyCCapabilityProperty cCapabilityProperty )
    {
        getProperties().removecCapabilityProperty );
    } //-- void removeProperty( CCapabilityProperty )

    
Set the flag determining if the capability is enabled.

Parameters:
enabled
    public void setEnabledboolean enabled )
    {
        this. = enabled;
    } //-- void setEnabled( boolean )

    
Set the id of the capability.

Parameters:
id
    public void setIdString id )
    {
        this. = id;
    } //-- void setId( String )

    
Set optional (user) notes about capability.

Parameters:
notes
    public void setNotesString notes )
    {
        this. = notes;
    } //-- void setNotes( String )

    
Set properties to configure the capability.

Parameters:
properties
    public void setPropertiesjava.util.List<CCapabilityPropertyproperties )
    {
        this. = properties;
    } //-- void setProperties( java.util.List )

    
Set the type id of the capability.

Parameters:
typeId
    public void setTypeIdString typeId )
    {
        this. = typeId;
    } //-- void setTypeId( String )

    
Set the version of capability properties.

Parameters:
version
    public void setVersionint version )
    {
        this. = version;
    } //-- void setVersion( int )
New to GrepCode? Check out our FAQ X