ufe 5.5
Universal Front End is a DCC-agnostic component that will allow a DCC to browse and edit data in multiple data models
codeWrapper.h
Go to the documentation of this file.
1#line 1 "S:/jenkins/workspace/ECP/ufe/ufe-full-python3.11-windows/ufe/include/codeWrapper.h"
2#ifndef _ufeCodeWrapper
3#define _ufeCodeWrapper
4// ===========================================================================
5// Copyright 2023 Autodesk, Inc. All rights reserved.
6//
7// Use of this software is subject to the terms of the Autodesk license
8// agreement provided at the time of installation or download, or which
9// otherwise accompanies this software in either electronic or hard copy form.
10// ===========================================================================
11
12#include "common/ufeExport.h"
13
14#include <memory>
15#include <string>
16#include <vector>
17
19
20class Selection;
21
29{
30public:
31 using Ptr = std::shared_ptr<CodeWrapper>;
32
33 virtual ~CodeWrapper();
34
37 virtual void prelude(const std::string& subOperation) = 0;
38
41 virtual void cleanup(const std::string& subOperation) = 0;
42};
43
48{
49public:
50 using Container = std::vector<CodeWrapper::Ptr>;
51
56 const Selection& selection,
57 const std::string& operationName
58 );
59
61 const Container& codeWrappers() const {
62 return fWrappers;
63 }
64
65private:
67};
68
69}
70
71#endif /* _ufeCodeWrapper */
A container of multiple CodeWrapper, one per UFE run-time that is involved in an operation.
Definition: codeWrapper.h:48
CodeWrapperContainer(const Selection &selection, const std::string &operationName)
Creates a container of wrapper, one for each run-time that is used in the selection.
std::vector< CodeWrapper::Ptr > Container
Definition: codeWrapper.h:50
const Container & codeWrappers() const
Retrieves the code wrappers that were created in the constructor.
Definition: codeWrapper.h:61
Wrap the execution of some other function, called sub-operation, with arbitrary prelude and cleanup v...
Definition: codeWrapper.h:29
std::shared_ptr< CodeWrapper > Ptr
Definition: codeWrapper.h:31
virtual void cleanup(const std::string &subOperation)=0
Function called after execution of some other code.
virtual void prelude(const std::string &subOperation)=0
Function called before execution of some other code.
virtual ~CodeWrapper()
Selection list for objects in the scene.
Definition: selection.h:28
std::string string(const Path &path)
#define UFE_NS_DEF
Definition: ufe.h:35
Definition of macros for symbol visibility.
#define UFE_SDK_DECL
Definition: ufeExport.h:36