All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.silentgo.core.route.Route Maven / Gradle / Ivy

There is a newer version: 0.0.49
Show newest version
package com.silentgo.core.route;

import java.util.regex.Matcher;

/**
 * Project : silentgo
 * com.silentgo.core.route
 *
 * @author teddyzhu
 *         

* Created by teddyzhu on 16/8/22. */ public class Route { private BasicRoute route; private boolean isRegex; private Matcher matcher; public BasicRoute getRoute() { return route; } public RegexRoute getRegexRoute() { return isRegex ? (RegexRoute) route : null; } public void setRoute(BasicRoute route) { this.route = route; } public boolean isRegex() { return isRegex; } public void setRegex(boolean regex) { isRegex = regex; } public Matcher getMatcher() { return isRegex ? matcher : null; } public void setMatcher(Matcher matcher) { this.matcher = matcher; } public Route(BasicRoute route, Matcher matcher) { this.route = route; this.isRegex = route instanceof RegexRoute; this.matcher = matcher; } }





© 2015 - 2024 Weber Informatics LLC | Privacy Policy