/*
*  Copyright (c) 2016, WSO2 Inc. (http://www.wso2.org) All Rights Reserved.
*
*  WSO2 Inc. licenses this file to you under the Apache License,
*  Version 2.0 (the "License"); you may not use this file except
*  in compliance with the License.
*  You may obtain a copy of the License at
*
*    http://www.apache.org/licenses/LICENSE-2.0
*
* Unless required by applicable law or agreed to in writing,
* software distributed under the License is distributed on an
* "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
* KIND, either express or implied.  See the License for the
* specific language governing permissions and limitations
* under the License.
*/

package org.wso2.carbon.apimgt.api.model.policy;

import java.io.Serializable;
import java.util.ArrayList;
import java.util.List;

public class Policy implements Serializable{
    private String policyName;
    private String userLevel;
    private String description;
    private QuotaPolicy defaultQuotaPolicy;
    private int tenantId;

    public Policy(String name){
        this.policyName=name;
    }

    public int getTenantId() {
        return tenantId;
    }

    public void setTenantId(int tenantId) {
        this.tenantId = tenantId;
    }

    public String getUserLevel() {
        return userLevel;
    }

    public void setUserLevel(String userLevel) {
        this.userLevel = userLevel;
    }

    public String getDescription() {
        return description;
    }

    public void setDescription(String description) {
        this.description = description;
    }

    public String getPolicyName() {
        return policyName;
    }

    public void setPolicyName(String policyName) {
        this.policyName = policyName;
    }

    public void setDefaultQuotaPolicy(QuotaPolicy defaultQuotaPolicy) {
        this.defaultQuotaPolicy = defaultQuotaPolicy;
    }

    public QuotaPolicy getDefaultQuotaPolicy() {
        return defaultQuotaPolicy;
    }

    @Override
    public String toString() {
        return "Policy{" +
                "defaultQuotaPolicy=" + defaultQuotaPolicy +
                ", policyName='" + policyName + '\'' +
                ", userLevel='" + userLevel + '\'' +
                ", description='" + description + '\'' +
                ", tenantId=" + tenantId +
                '}';
    }
}

@@ -831,17 +831,44 @@
 alizable
-%7B
+ %7B%0A    private int policyId;
 %0A    pri
@@ -1083,15 +1083,73 @@
 Name
-=
+ = 
 name;%0A
+        this.policyId = -1;%0A        this.tenantId = -1;%0A
     
@@ -2017,24 +2017,172 @@
 icy;%0A    %7D%0A%0A
+    public int getPolicyId() %7B%0A        return policyId;%0A    %7D%0A%0A    public void setPolicyId(int policyId) %7B%0A        this.policyId = policyId;%0A    %7D%0A%0A
     @Overrid

Add policyId to Policy class