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

org.yeauty.support.DefaultPathMatcher Maven / Gradle / Ivy

There is a newer version: 0.12.0
Show newest version
package org.yeauty.support;

import io.netty.channel.Channel;
import io.netty.handler.codec.http.QueryStringDecoder;


public class DefaultPathMatcher implements WsPathMatcher {

    private String pattern;

    public DefaultPathMatcher(String pattern) {
        this.pattern = pattern;
    }

    @Override
    public String getPattern() {
        return this.pattern;
    }

    @Override
    public boolean matchAndExtract(QueryStringDecoder decoder, Channel channel) {
        if (!pattern.equals(decoder.path())) {
            return false;
        }
        return true;
    }
}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy