blob: 547e7d4aac82b67cfb1acff41c454a68796081d1 [file] [log] [blame]
// Copyright 2018 The Chromium OS Authors. All rights reserved.
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.
#ifndef SMBPROVIDER_ITERATOR_SHARE_ITERATOR_H_
#define SMBPROVIDER_ITERATOR_SHARE_ITERATOR_H_
#include "smbprovider/iterator/directory_iterator.h"
#include "smbprovider/smbprovider_helper.h"
namespace smbprovider {
// ShareIterator is an implementation of BaseDirectoryIterator that only
// iterates through shares.
class ShareIterator : public BaseDirectoryIterator {
using BaseDirectoryIterator::BaseDirectoryIterator;
public:
ShareIterator(ShareIterator&& other) = default;
protected:
bool ShouldIncludeEntryType(uint32_t smbc_type) const override {
return IsSmbShare(smbc_type);
}
DISALLOW_COPY_AND_ASSIGN(ShareIterator);
};
} // namespace smbprovider
#endif // SMBPROVIDER_ITERATOR_SHARE_ITERATOR_H_