Package cli_fmw.delegate.directory.simple

Source Code of cli_fmw.delegate.directory.simple.DirectorySimpleItem

/*
* To change this template, choose Tools | Templates
* and open the template in the editor.
*/

package cli_fmw.delegate.directory.simple;

import cli_fmw.delegate.directory.DirectoryItem;
import cli_fmw.main.ClipsException;
import framework.beans.directory.DirectoryItemDetails;



/**
*
* @author axe
*/
public abstract class DirectorySimpleItem
        extends DirectoryItem<DirectoryItemDetails> {

    private int type;
   
    public DirectorySimpleItem(DirectoryItemDetails details, int type) {
        super(details);
        this.type = type;
    }

    public void setExtKey(String extkey) throws ClipsException{
        saveExtKeyDB(extkey);
    }

    final private void saveExtKeyDB(String extkey) throws ClipsException {
       if(isInDirectory()) {
            DirectoryItemDetails newDetails = getDetailsCopy();
            newDetails.external_key = extkey;
            saveDetails(newDetails);
        } else {
            getDetails().external_key = extkey;
        }
    }

    public String getExtKey() {
        return getDetails().external_key;
    }
}
TOP

Related Classes of cli_fmw.delegate.directory.simple.DirectorySimpleItem

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.