fix(emqx_types): type spec refs does not exist file.
This commit is contained in:
parent
2fe96a3ad0
commit
9c95557bfc
|
@ -20,8 +20,8 @@
|
||||||
|
|
||||||
-include_lib("emqx/include/emqx_mqtt.hrl").
|
-include_lib("emqx/include/emqx_mqtt.hrl").
|
||||||
|
|
||||||
-type qos() :: emqx_mqtt_types:qos_name() | emqx_mqtt_types:qos().
|
-type qos() :: emqx_types:qos_name() | emqx_types:qos().
|
||||||
-type topic() :: emqx_topic:topic().
|
-type topic() :: emqx_types:topic().
|
||||||
-type handler() :: fun((CorrData :: binary(), ReqPayload :: binary()) -> RspPayload :: binary()).
|
-type handler() :: fun((CorrData :: binary(), ReqPayload :: binary()) -> RspPayload :: binary()).
|
||||||
|
|
||||||
-spec start_link(topic(), qos(), handler(), emqtt:options()) ->
|
-spec start_link(topic(), qos(), handler(), emqtt:options()) ->
|
||||||
|
|
|
@ -104,7 +104,7 @@
|
||||||
]).
|
]).
|
||||||
|
|
||||||
-type id() :: atom() | string() | pid().
|
-type id() :: atom() | string() | pid().
|
||||||
-type qos() :: emqx_mqtt_types:qos().
|
-type qos() :: emqx_types:qos().
|
||||||
-type config() :: map().
|
-type config() :: map().
|
||||||
-type batch() :: [emqx_connector_mqtt_msg:exp_msg()].
|
-type batch() :: [emqx_connector_mqtt_msg:exp_msg()].
|
||||||
-type ack_ref() :: term().
|
-type ack_ref() :: term().
|
||||||
|
|
|
@ -265,7 +265,7 @@ payload(Path) ->
|
||||||
|
|
||||||
%% @doc Check if a topic_filter contains a specific topic
|
%% @doc Check if a topic_filter contains a specific topic
|
||||||
%% TopicFilters = [{<<"t/a">>, #{qos => 0}].
|
%% TopicFilters = [{<<"t/a">>, #{qos => 0}].
|
||||||
-spec(contains_topic(emqx_mqtt_types:topic_filters(), emqx_types:topic())
|
-spec(contains_topic(emqx_types:topic_filters(), emqx_types:topic())
|
||||||
-> true | false).
|
-> true | false).
|
||||||
contains_topic(TopicFilters, Topic) ->
|
contains_topic(TopicFilters, Topic) ->
|
||||||
case find_topic_filter(Topic, TopicFilters, fun eq/2) of
|
case find_topic_filter(Topic, TopicFilters, fun eq/2) of
|
||||||
|
@ -278,7 +278,7 @@ contains_topic(TopicFilters, Topic, QoS) ->
|
||||||
_ -> false
|
_ -> false
|
||||||
end.
|
end.
|
||||||
|
|
||||||
-spec(contains_topic_match(emqx_mqtt_types:topic_filters(), emqx_types:topic())
|
-spec(contains_topic_match(emqx_types:topic_filters(), emqx_types:topic())
|
||||||
-> true | false).
|
-> true | false).
|
||||||
contains_topic_match(TopicFilters, Topic) ->
|
contains_topic_match(TopicFilters, Topic) ->
|
||||||
case find_topic_filter(Topic, TopicFilters, fun emqx_topic:match/2) of
|
case find_topic_filter(Topic, TopicFilters, fun emqx_topic:match/2) of
|
||||||
|
|
Loading…
Reference in New Issue