chromium/third_party/blink/renderer/modules/ml/webnn/ml_operator.h

// Copyright 2022 The Chromium Authors
// Use of this source code is governed by a BSD-style license that can be
// found in the LICENSE file.

#ifndef THIRD_PARTY_BLINK_RENDERER_MODULES_ML_WEBNN_ML_OPERATOR_H_
#define THIRD_PARTY_BLINK_RENDERER_MODULES_ML_WEBNN_ML_OPERATOR_H_

#include "services/webnn/public/mojom/webnn_graph.mojom-blink.h"
#include "third_party/abseil-cpp/absl/types/variant.h"
#include "third_party/blink/renderer/modules/modules_export.h"
#include "third_party/blink/renderer/platform/bindings/dictionary_base.h"
#include "third_party/blink/renderer/platform/heap/collection_support/heap_vector.h"
#include "third_party/blink/renderer/platform/heap/garbage_collected.h"
#include "third_party/blink/renderer/platform/heap/member.h"
#include "third_party/blink/renderer/platform/heap/visitor.h"

namespace blink {

class MLArgMinMaxOptions;
class MLGraphBuilder;
class MLOperand;
class MLOperatorOptions;
class MLGruCellOptions;
class MLLstmOptions;
class MLLstmCellOptions;
class MLPadOptions;
class MLSplitOptions;

class MODULES_EXPORT MLOperator : public GarbageCollected<MLOperator> {};

// TODO: crbug.com/325612086 - Remove all these subclasses. This information
// should all be contained within the respective mojo Operation struct.

class MODULES_EXPORT MLArgMinMaxOperator : public MLOperator {};

class MODULES_EXPORT MLConcatOperator : public MLOperator {};

class MODULES_EXPORT MLLstmOperator : public MLOperator {};

class MODULES_EXPORT MLLstmCellOperator : public MLOperator {};

class MODULES_EXPORT MLGruOperator : public MLOperator {};

class MODULES_EXPORT MLGruCellOperator : public MLOperator {};

class MODULES_EXPORT MLPadOperator : public MLOperator {};

class MODULES_EXPORT MLSliceOperator : public MLOperator {};

class MODULES_EXPORT MLSoftmaxOperator : public MLOperator {};

class MODULES_EXPORT MLSplitOperator : public MLOperator {};
}  // namespace blink

#endif  // THIRD_PARTY_BLINK_RENDERER_MODULES_ML_WEBNN_ML_OPERATOR_H_