<commit_before>/*******************************************************************************
 * Copyright (c) 2011, 2017 Eurotech and/or its affiliates and others
 *
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 *     Eurotech - initial API and implementation
 *******************************************************************************/
package org.eclipse.kapua.app.console.module.authorization.client.role;

import com.google.gwt.core.client.GWT;
import com.google.gwt.user.client.Element;
import org.eclipse.kapua.app.console.module.api.client.resources.icons.IconSet;
import org.eclipse.kapua.app.console.module.api.client.resources.icons.KapuaIcon;
import org.eclipse.kapua.app.console.module.api.client.ui.tab.KapuaTabItem;
import org.eclipse.kapua.app.console.module.api.client.ui.view.AbstractEntityView;
import org.eclipse.kapua.app.console.module.api.shared.model.GwtSession;
import org.eclipse.kapua.app.console.module.authorization.client.messages.ConsoleRoleMessages;
import org.eclipse.kapua.app.console.module.authorization.shared.model.GwtRole;
import org.eclipse.kapua.app.console.module.authorization.shared.model.GwtRolePermission;

public class RoleTabPermissionGrid extends KapuaTabItem<GwtRole> {

    private static final ConsoleRoleMessages MSGS = GWT.create(ConsoleRoleMessages.class);
    RolePermissionGrid rolePermissionGrid;

    public RoleTabPermissionGrid(GwtSession currentSession) {
        this(currentSession, null);
    }

    public RoleTabPermissionGrid(GwtSession currentSession, AbstractEntityView<GwtRolePermission> entityView) {
        super(currentSession, MSGS.roleTabPermissionGridTitle(), new KapuaIcon(IconSet.TASKS));

        rolePermissionGrid = new RolePermissionGrid(entityView, currentSession);
        rolePermissionGrid.setRefreshOnRender(false);<commit_msg>Changed icon in roles -> permissions tab to look same as icon in users -> permissions (#1386)<commit_after>/*******************************************************************************
 * Copyright (c) 2011, 2018 Eurotech and/or its affiliates and others
 *
 * All rights reserved. This program and the accompanying materials
 * are made available under the terms of the Eclipse Public License v1.0
 * which accompanies this distribution, and is available at
 * http://www.eclipse.org/legal/epl-v10.html
 *
 * Contributors:
 *     Eurotech - initial API and implementation
 *******************************************************************************/
package org.eclipse.kapua.app.console.module.authorization.client.role;

import com.google.gwt.core.client.GWT;
import com.google.gwt.user.client.Element;
import org.eclipse.kapua.app.console.module.api.client.resources.icons.IconSet;
import org.eclipse.kapua.app.console.module.api.client.resources.icons.KapuaIcon;
import org.eclipse.kapua.app.console.module.api.client.ui.tab.KapuaTabItem;
import org.eclipse.kapua.app.console.module.api.client.ui.view.AbstractEntityView;
import org.eclipse.kapua.app.console.module.api.shared.model.GwtSession;
import org.eclipse.kapua.app.console.module.authorization.client.messages.ConsoleRoleMessages;
import org.eclipse.kapua.app.console.module.authorization.shared.model.GwtRole;
import org.eclipse.kapua.app.console.module.authorization.shared.model.GwtRolePermission;

public class RoleTabPermissionGrid extends KapuaTabItem<GwtRole> {

    private static final ConsoleRoleMessages MSGS = GWT.create(ConsoleRoleMessages.class);
    RolePermissionGrid rolePermissionGrid;

    public RoleTabPermissionGrid(GwtSession currentSession) {
        this(currentSession, null);
    }

    public RoleTabPermissionGrid(GwtSession currentSession, AbstractEntityView<GwtRolePermission> entityView) {
        super(currentSession, MSGS.roleTabPermissionGridTitle(), new KapuaIcon(IconSet.CHECK_CIRCLE));

        rolePermissionGrid = new RolePermissionGrid(entityView, currentSession);
        rolePermissionGrid.setRefreshOnRender(false);
{'fraction_non_alphanumeric': 0.16407185628742516, 'fraction_numerical': 0.006706586826347305, 'mean_word_length': 5.703049759229534, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '4051069', 'n_tokens_mistral': 1151, 'n_tokens_neox': 1102, 'n_words': 215}