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

org.joinedworkz.common.info.ResourceOperationInfo.xtend Maven / Gradle / Ivy

package org.joinedworkz.common.info

import java.util.List
import org.eclipse.xtend.lib.annotations.Accessors
import org.joinedworkz.core.model.CmnOperationParameter
import org.joinedworkz.core.model.CmnResourceOperation
import org.joinedworkz.core.model.CmnResource
import org.joinedworkz.core.model.Verb

@Accessors
class ResourceOperationInfo {
    
    final String parentPath
    final Verb verb;
    final CmnResourceOperation operation
    final CmnResource operationResource
    final String idPrefix
    
    String path;
    CmnResource resource
    List parentParameters
    
    new (String parentPath, CmnResourceOperation operation,String idPrefix) {
        this.parentPath = parentPath
        this.operation = operation
        this.operationResource = operation.container as CmnResource
        this.verb = operation.verb;
        this.idPrefix = idPrefix
    }
    
    def addParentPathParameters(List parameters) {
        if (parameters !== null) {
            if (parentParameters === null) {
                parentParameters = newArrayList
            }
            parentParameters.addAll(parameters)
        }
    }
    
}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy