All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.kevoree.modeling.KModel Maven / Gradle / Ivy

There is a newer version: 4.27.0.2
Show newest version
package org.kevoree.modeling;

import org.kevoree.modeling.defer.KDefer;
import org.kevoree.modeling.memory.manager.KDataManager;
import org.kevoree.modeling.meta.KMetaClass;
import org.kevoree.modeling.meta.KMetaModel;
import org.kevoree.modeling.meta.KMetaOperation;
import org.kevoree.modeling.traversal.KTraversal;

public interface KModel {

    /**
     * Current Model state variables accessor
     */
    long key();

    A newUniverse();

    A universe(long key);

    KDataManager manager();

    KMetaModel metaModel();

    /**
     * Create a new KDefer
     */
    KDefer defer();

    /**
     * Operation Management
     */
    void setOperation(KMetaOperation metaOperation, KOperation operation);

    void setOperationByName(String metaClassName, String metaOperationName, KOperation operation);

    /**
     * Life cycle management
     */
    void save(KCallback callback);

    void connect(KCallback callback);

    void disconnect(KCallback callback);

    /**
     * Lookup primitives
     */
    void lookup(long universe, long time, long uuid, KCallback callback);

    void lookupAllObjects(long universe, long time, long[] uuids, KCallback callback);

    void lookupAllTimes(long universe, long[] times, long uuid, KCallback callback);

    KPreparedLookup createPreparedLookup(int size);

    void lookupPrepared(KPreparedLookup prepared, KCallback callback);

    /**
     * Domain objets Creation methods
     */
    KObject createByName(String metaClassName, long universe, long time);

    KObject create(KMetaClass clazz, long universe, long time);

    KListener createListener(long universe);

    KModelContext createModelContext();

    KTraversal createTraversal(KObject[] startingElements);

    KTraversal createReusableTraversal();

    /**
     * Index management method
     */

    void indexByName(long universe, long time, String indexName, KCallback callback);

    void find(KMetaClass metaClass, long universe, long time, String attributes, KCallback callback);

    void findByName(String indexName, long universe, long time, String attributes, KCallback callback);

    void findAll(KMetaClass metaClass, long universe, long time, KCallback callback);

    void findAllByName(String indexName, long universe, long time, KCallback callback);

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy