diff --git a/api/@ohos.contact.d.ts b/api/@ohos.contact.d.ts index 8242ea2aa908223940061fe16f7ff3421e38f5e7..6b3da54f25bcb912a9e7398e5b6323caccf7e657 100644 --- a/api/@ohos.contact.d.ts +++ b/api/@ohos.contact.d.ts @@ -26,7 +26,7 @@ declare namespace contact { /** * Creates a contact. * - *
Permissions required: {@code ohos.permission.READ_CONTACTS} and {@code ohos.permission.WRITE_CONTACTS} + *
Permissions required: {@code ohos.permission.WRITE_CONTACTS}
*
* @param contact Indicates the contact information.
* @return Returns the contact ID (which can be obtained by {@link Contact#getId()}) if the creation is successful;
@@ -35,10 +35,22 @@ declare namespace contact {
function addContact(contact: Contact, callback: AsyncCallback Permissions required: {@code ohos.permission.READ_CONTACTS}
+ *
+ * @return Returns the contact list which user select;
+ * returns empty contact list if user not select.
+ * @syscap SystemCapability.Applications.ContactsData, SystemCapability.Applications.Contacts
+ */
+ function selectContact(callback: AsyncCallback Permissions required: {@code ohos.permission.READ_CONTACTS} and {@code ohos.permission.WRITE_CONTACTS}
+ * Permissions required: {@code ohos.permission.WRITE_CONTACTS}
*
* @param key Indicates the unique query key of a contact to delete.
* @return Returns {@code true} if the contact is deleted; returns {@code false} otherwise.
@@ -49,7 +61,7 @@ declare namespace contact {
/**
* Queries a specified contact of specified attributes.
*
- * Permissions required: {@code ohos.permission.READ_CONTACTS} and {@code ohos.permission.WRITE_CONTACTS}
+ * Permissions required: {@code ohos.permission.READ_CONTACTS}
*
* @param key Indicates the unique query key of a contact.
* @param holder Indicates the contact holder. If this parameter is null, the default holder is used for matching.
@@ -65,7 +77,7 @@ declare namespace contact {
/**
* Queries contacts with query conditions.
*
- * Permissions required: {@code ohos.permission.READ_CONTACTS} and {@code ohos.permission.WRITE_CONTACTS}
+ * Permissions required: {@code ohos.permission.READ_CONTACTS}
*
* @param holder Indicates the contact holder. If this parameter is null, the default holder is used for matching.
* @param attrs Indicates the contact attributes. If this parameter is null, all attributes are used for matching.
@@ -80,7 +92,7 @@ declare namespace contact {
/**
* Queries contacts by a specified email address, contact holder, and contact attributes.
*
- * Permissions required: {@code ohos.permission.READ_CONTACTS} and {@code ohos.permission.WRITE_CONTACTS}
+ * Permissions required: {@code ohos.permission.READ_CONTACTS}
*
* @param email Indicates the email address.
* @param holder Indicates the contact holder. If this parameter is null, the default holder is used for matching.
@@ -96,7 +108,7 @@ declare namespace contact {
/**
* Queries contacts by a phone number, holder, and contact attribute.
*
- * Permissions required: {@code ohos.permission.READ_CONTACTS} and {@code ohos.permission.WRITE_CONTACTS}.
+ * Permissions required: {@code ohos.permission.READ_CONTACTS}
*
* @param phoneNumber Indicates the phone number. Only full match is supported, and wildcards are not supported.
* @param holder Indicates the contact holder. If this parameter is null, the default holder is used for matching.
@@ -113,7 +125,7 @@ declare namespace contact {
/**
* Queries contact groups.
*
- * Permissions required: {@code ohos.permission.READ_CONTACTS} and {@code ohos.permission.WRITE_CONTACTS}
+ * Permissions required: {@code ohos.permission.READ_CONTACTS}
*
* @param holder Indicates the contact holder. If this parameter is null, the default holder is used for matching.
* @return Returns the contact group list.
@@ -125,7 +137,7 @@ declare namespace contact {
/**
* Queries contact holders.
*
- * Permissions required: {@code ohos.permission.READ_CONTACTS} and {@code ohos.permission.WRITE_CONTACTS}
+ * Permissions required: {@code ohos.permission.READ_CONTACTS}
*
* @return Returns the {@code Holder} list object.
*/
@@ -135,7 +147,7 @@ declare namespace contact {
/**
* Obtains the query key of a contact based on a specified ID and holder.
*
- * Permissions required: {@code ohos.permission.READ_CONTACTS} and {@code ohos.permission.WRITE_CONTACTS}
+ * Permissions required: {@code ohos.permission.READ_CONTACTS}
*
* @param id Indicates the contact ID.
* @param holder Indicates the contact holder. If this parameter is null, the default holder is used for matching.
@@ -148,7 +160,7 @@ declare namespace contact {
/**
* Queries information about "my card".
*
- * Permissions required: {@code ohos.permission.READ_CONTACTS} and {@code ohos.permission.WRITE_CONTACTS}
+ * Permissions required: {@code ohos.permission.READ_CONTACTS}
*
* @param attrs Indicates the contact attributes. If this parameter is null, all attributes are used for matching.
* @return Returns information about "my card".
@@ -160,7 +172,7 @@ declare namespace contact {
/**
* Updates specified attributes of a contact.
*
- * Permissions required: {@code ohos.permission.READ_CONTACTS} and {@code ohos.permission.WRITE_CONTACTS}
+ * Permissions required: {@code ohos.permission.WRITE_CONTACTS}
*
* @param contact Indicates the contact whose information is to update.
* @param attrs Indicates the contact attributes to update. If this parameter is null,
@@ -174,7 +186,7 @@ declare namespace contact {
/**
* Checks whether the contact ID is in the local phone book.
*
- * Permissions required: {@code ohos.permission.READ_CONTACTS} and {@code ohos.permission.WRITE_CONTACTS}
+ * Permissions required: {@code ohos.permission.READ_CONTACTS}
*
* @param id Indicates the contact ID.
* @return Returns {@code true} if the contact ID is in the local phone book; returns {@code false} otherwise.
@@ -185,6 +197,8 @@ declare namespace contact {
/**
* Checks whether the contact ID is of "my card".
*
+ * Permissions required: {@code ohos.permission.READ_CONTACTS}
+ *
* @param id Indicates the contact ID.
* @return Returns {@code true} if the contact ID is of "my card"; returns {@code false} otherwise.
*/
diff --git a/api/@ohos.net.connection.d.ts b/api/@ohos.net.connection.d.ts
index 3ff974a7558c559153b9f2c6c1ff02df4843297e..243336d3ee61ad3cf734f6ff5851f2ee2286ab85 100644
--- a/api/@ohos.net.connection.d.ts
+++ b/api/@ohos.net.connection.d.ts
@@ -170,16 +170,6 @@ declare namespace connection {
export interface NetHandle {
netId: number;
- /**
- * Binds a TCPSocket or UDPSocket to the current network. All data flows from
- * the socket will use this network, without being subject to {@link setAppNet}.
- * Before using this method, ensure that the socket is disconnected.
- *
- * @param socketParam Indicates the TCPSocket or UDPSocket object.
- */
- bindSocket(socketParam: TCPSocket | UDPSocket, callback: AsyncCallback