protected override void ProcessRecord() { var itemList = DataLakeAnalyticsClient.GetCatalogItem(ResourceGroupName, Account, Path, ItemType); if (itemList.Count == 1) { WriteObject(itemList[0]); } else { WriteObject(itemList, true); } }
public override void ExecuteCmdlet() { var itemList = DataLakeAnalyticsClient.GetCatalogItem(ResourceGroupName, Account, Path, ItemType); if (itemList.Count == 1) { WriteObject(itemList[0]); } else { WriteObject(itemList, true); } }
protected override void ProcessRecord() { try { DataLakeAnalyticsClient.GetCatalogItem(ResourceGroupName, Account, Path, ItemType); WriteObject(true); } catch (Exception e) { if (e.Message.Equals(string.Format(Resources.InvalidCatalogPath, Path.FullCatalogItemPath), StringComparison.CurrentCultureIgnoreCase)) { throw; } WriteObject(false); } }