001/* 002 * VM-Operator 003 * Copyright (C) 2023 Michael N. Lipp 004 * 005 * This program is free software: you can redistribute it and/or modify 006 * it under the terms of the GNU Affero General Public License as 007 * published by the Free Software Foundation, either version 3 of the 008 * License, or (at your option) any later version. 009 * 010 * This program is distributed in the hope that it will be useful, 011 * but WITHOUT ANY WARRANTY; without even the implied warranty of 012 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 013 * GNU Affero General Public License for more details. 014 * 015 * You should have received a copy of the GNU Affero General Public License 016 * along with this program. If not, see <https://www.gnu.org/licenses/>. 017 */ 018 019package org.jdrupes.vmoperator.manager.events; 020 021import org.jgrapes.core.Channel; 022import org.jgrapes.core.Event; 023 024/** 025 * Modifies a VM. 026 */ 027public class ModifyVm extends Event<Void> { 028 029 private final String name; 030 private final String path; 031 private final Object value; 032 033 /** 034 * Instantiates a new modify vm event. 035 * 036 * @param channels the channels 037 * @param name the name 038 */ 039 public ModifyVm(String name, String path, Object value, 040 Channel... channels) { 041 super(channels); 042 this.name = name; 043 this.path = path; 044 this.value = value; 045 } 046 047 /** 048 * Gets the name. 049 * 050 * @return the name 051 */ 052 public String name() { 053 return name; 054 } 055 056 /** 057 * Gets the path. 058 * 059 * @return the path 060 */ 061 public String path() { 062 return path; 063 } 064 065 /** 066 * Gets the value. 067 * 068 * @return the value 069 */ 070 public Object value() { 071 return value; 072 } 073 074}