use of org.batfish.datamodel.vendor_family.cisco.LoggingType in project batfish by batfish.
the class CiscoControlPlaneExtractor method exitLogging_trap.
@Override
public void exitLogging_trap(Logging_trapContext ctx) {
if (_no) {
return;
}
Integer severityNum = null;
String severity = null;
if (ctx.logging_severity() != null) {
severityNum = toLoggingSeverityNum(ctx.logging_severity());
severity = toLoggingSeverity(ctx.logging_severity());
}
Logging logging = _configuration.getCf().getLogging();
LoggingType trap = logging.getTrap();
if (trap == null) {
trap = new LoggingType();
logging.setTrap(trap);
}
trap.setSeverity(severity);
trap.setSeverityNum(severityNum);
}
use of org.batfish.datamodel.vendor_family.cisco.LoggingType in project batfish by batfish.
the class CiscoControlPlaneExtractor method exitLogging_console.
@Override
public void exitLogging_console(Logging_consoleContext ctx) {
if (_no) {
return;
}
Integer severityNum = null;
String severity = null;
if (ctx.logging_severity() != null) {
severityNum = toLoggingSeverityNum(ctx.logging_severity());
severity = toLoggingSeverity(ctx.logging_severity());
}
Logging logging = _configuration.getCf().getLogging();
LoggingType console = logging.getConsole();
if (console == null) {
console = new LoggingType();
logging.setConsole(console);
}
console.setSeverity(severity);
console.setSeverityNum(severityNum);
}
Aggregations