Search in sources :

Example 6 with Route6FilterLine

use of org.batfish.representation.juniper.Route6FilterLine in project batfish by batfish.

the class ConfigurationBuilder method enterPopsfrf_upto.

@Override
public void enterPopsfrf_upto(Popsfrf_uptoContext ctx) {
    int maxPrefixLength = toInt(ctx.high);
    if (_currentRouteFilterPrefix != null) {
        // ipv4
        Route4FilterLine line = new Route4FilterLineUpTo(_currentRouteFilterPrefix, maxPrefixLength);
        _currentRouteFilterLine = _currentRouteFilter.insertLine(line, Route4FilterLine.class);
    } else if (_currentRoute6FilterPrefix != null) {
        // ipv6
        Route6FilterLine line = new Route6FilterLineUpTo(_currentRoute6FilterPrefix, maxPrefixLength);
        _currentRoute6FilterLine = _currentRouteFilter.insertLine(line, Route6FilterLine.class);
    }
}
Also used : Route6FilterLine(org.batfish.representation.juniper.Route6FilterLine) Route6FilterLineUpTo(org.batfish.representation.juniper.Route6FilterLineUpTo) Route4FilterLine(org.batfish.representation.juniper.Route4FilterLine) Route4FilterLineUpTo(org.batfish.representation.juniper.Route4FilterLineUpTo)

Example 7 with Route6FilterLine

use of org.batfish.representation.juniper.Route6FilterLine in project batfish by batfish.

the class ConfigurationBuilder method enterPopsfrf_then.

@Override
public void enterPopsfrf_then(Popsfrf_thenContext ctx) {
    if (_currentRouteFilterPrefix != null) {
        // ipv4
        Route4FilterLine line = _currentRouteFilterLine;
        _currentPsThens = line.getThens();
    } else if (_currentRoute6FilterPrefix != null) {
        // ipv6
        Route6FilterLine line = _currentRoute6FilterLine;
        _currentPsThens = line.getThens();
    }
}
Also used : Route6FilterLine(org.batfish.representation.juniper.Route6FilterLine) Route4FilterLine(org.batfish.representation.juniper.Route4FilterLine)

Aggregations

Route4FilterLine (org.batfish.representation.juniper.Route4FilterLine)7 Route6FilterLine (org.batfish.representation.juniper.Route6FilterLine)7 Prefix (org.batfish.datamodel.Prefix)1 Prefix6 (org.batfish.datamodel.Prefix6)1 Route4FilterLineExact (org.batfish.representation.juniper.Route4FilterLineExact)1 Route4FilterLineLengthRange (org.batfish.representation.juniper.Route4FilterLineLengthRange)1 Route4FilterLineLonger (org.batfish.representation.juniper.Route4FilterLineLonger)1 Route4FilterLineOrLonger (org.batfish.representation.juniper.Route4FilterLineOrLonger)1 Route4FilterLineThrough (org.batfish.representation.juniper.Route4FilterLineThrough)1 Route4FilterLineUpTo (org.batfish.representation.juniper.Route4FilterLineUpTo)1 Route6FilterLineExact (org.batfish.representation.juniper.Route6FilterLineExact)1 Route6FilterLineLengthRange (org.batfish.representation.juniper.Route6FilterLineLengthRange)1 Route6FilterLineLonger (org.batfish.representation.juniper.Route6FilterLineLonger)1 Route6FilterLineOrLonger (org.batfish.representation.juniper.Route6FilterLineOrLonger)1 Route6FilterLineThrough (org.batfish.representation.juniper.Route6FilterLineThrough)1 Route6FilterLineUpTo (org.batfish.representation.juniper.Route6FilterLineUpTo)1