[ 
https://issues.apache.org/jira/browse/HADOOP-19802?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=18060193#comment-18060193
 ] 

ASF GitHub Bot commented on HADOOP-19802:
-----------------------------------------

manika137 commented on code in PR #8229:
URL: https://github.com/apache/hadoop/pull/8229#discussion_r2838979474


##########
hadoop-tools/hadoop-azure/src/main/java/org/apache/hadoop/fs/azurebfs/contracts/services/ContainerListEntrySchema.java:
##########
@@ -0,0 +1,286 @@
+/**
+ * Licensed to the Apache Software Foundation (ASF) under one
+ * or more contributor license agreements.  See the NOTICE file
+ * distributed with this work for additional information
+ * regarding copyright ownership.  The ASF licenses this file
+ * to you under the Apache License, Version 2.0 (the
+ * "License"); you may not use this file except in compliance
+ * with the License.  You may obtain a copy of the License at
+ *
+ *     http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+
+package org.apache.hadoop.fs.azurebfs.contracts.services;
+
+import java.util.HashMap;
+import java.util.Map;
+
+/**
+ * List result entry schema for the Azure Blob Storage List Containers API.
+ *
+ * Represents a single container and its associated properties returned by
+ * the Blob endpoint container listing operation.
+ */
+public class ContainerListEntrySchema implements ListResultEntrySchema {
+
+  private String name;
+  private String version;
+  private Boolean deleted = false;
+  private Long lastModified;
+  private String eTag;
+  private String leaseStatus;
+  private String leaseState;
+  private String leaseDuration;
+  private String publicAccess;
+  private Boolean hasImmutabilityPolicy;
+  private Boolean hasLegalHold;
+  private Long deletedTime;
+  private Integer remainingRetentionDays;
+
+  private final Map<String, String> metadata = new HashMap<>();
+
+  /**
+   * {@inheritDoc}
+   */
+  @Override
+  public String name() {
+    return name;
+  }
+
+  /**
+   * {@inheritDoc}
+   *
+   * Containers are treated as directories in ABFS semantics.
+   */
+  @Override
+  public Boolean isDirectory() {
+    return Boolean.TRUE;
+  }
+
+  /**
+   * {@inheritDoc}
+   */
+  @Override
+  public String eTag() {
+    return eTag;
+  }
+
+  /**
+   * {@inheritDoc}
+   *
+   * Returns the container last-modified time as a string, if available.
+   */
+  @Override
+  public String lastModified() {
+    return lastModified != null ? String.valueOf(lastModified) : null;

Review Comment:
   nit: we can use Objects.toString(lastModified, null)





> ABFS: Remove SDK dependency in hadoop-azure
> -------------------------------------------
>
>                 Key: HADOOP-19802
>                 URL: https://issues.apache.org/jira/browse/HADOOP-19802
>             Project: Hadoop Common
>          Issue Type: Sub-task
>    Affects Versions: 3.4.2
>            Reporter: Anmol Asrani
>            Assignee: Anmol Asrani
>            Priority: Major
>              Labels: pull-request-available
>
> Remove use of SDK from hadoop-azure



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to