Skip to content

Commit

Permalink
[Service Bus] Type docs fix - Added @internal and @ignore tags for in…
Browse files Browse the repository at this point in the history
…ternal methods (Azure#11427)

* logger, isError, toAmqpAnnotatedMessage changed to internal

* SubQueue renamed to _SubQueue and changed to internal for jsdoc

* Revert "SubQueue renamed to _SubQueue and changed to internal for jsdoc"

This reverts commit b97b682.
  • Loading branch information
mohsin-mehmood authored and deyaaeldeen committed Sep 25, 2020
1 parent efd50e5 commit 337d70d
Show file tree
Hide file tree
Showing 3 changed files with 10 additions and 2 deletions.
2 changes: 2 additions & 0 deletions sdk/servicebus/service-bus/src/log.ts
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,8 @@ import { createClientLogger } from "@azure/logger";
/**
* The @azure/logger configuration for this package.
* This will output logs using the `azure:event-hubs` namespace prefix.
* @ignore
* @internal
*/
export const logger = createClientLogger("service-bus");

Expand Down
2 changes: 2 additions & 0 deletions sdk/servicebus/service-bus/src/serviceBusMessage.ts
Original file line number Diff line number Diff line change
Expand Up @@ -826,6 +826,8 @@ export function fromAmqpMessage(
* @export
* @param {AmqpMessage} msg
* @returns {AmqpAnnotatedMessage}
* @internal
* @ignore
*/
export function toAmqpAnnotatedMessage(msg: AmqpMessage): AmqpAnnotatedMessage {
const messageHeader = MessageHeader.fromAmqpMessageHeader(msg);
Expand Down
8 changes: 6 additions & 2 deletions sdk/servicebus/service-bus/src/util/errors.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,10 +7,10 @@ import { ConnectionContext } from "../connectionContext";
import { AmqpError } from "rhea-promise";

/**
* Error message to use when EntityPath in connection string does not match the
* Error message to use when EntityPath in connection string does not match the
* queue or topic name passed to the methods in the ServiceBusClient that create
* senders and receivers.
*
*
* @internal
* @ignore
*/
Expand Down Expand Up @@ -217,6 +217,10 @@ export function logError(err: Error | AmqpError | undefined, ...args: any[]): vo
logErrorStackTrace(err);
}

/**
* @internal
* @ignore
*/
function isError(err: Error | AmqpError | undefined): err is Error {
return err != null && (err as any).name != null;
}

0 comments on commit 337d70d

Please sign in to comment.