MCPcopy Create free account
hub / github.com/Kitware/ParaView / GetPrototypeProxy

Method GetPrototypeProxy

Remoting/ServerManager/vtkSMSessionProxyManager.cxx:392–428  ·  view source on GitHub ↗

--------------------------------------------------------------------------- No errors are raised if a proxy definition for the requested proxy is not found.

Source from the content-addressed store, hash-verified

390// No errors are raised if a proxy definition for the requested proxy is not
391// found.
392vtkSMProxy* vtkSMSessionProxyManager::GetPrototypeProxy(const char* groupname, const char* name)
393{
394 if (!this->ProxyDefinitionManager)
395 {
396 return nullptr;
397 }
398
399 std::string protype_group = groupname;
400 protype_group += "_prototypes";
401 vtkSMProxy* proxy = this->GetProxy(protype_group.c_str(), name);
402 if (proxy)
403 {
404 return proxy;
405 }
406
407 // silently ask for the definition. If not found return nullptr.
408 vtkPVXMLElement* xmlElement =
409 this->ProxyDefinitionManager->GetCollapsedProxyDefinition(groupname, name, nullptr, false);
410 if (xmlElement == nullptr)
411 {
412 // No definition was located for the requested proxy.
413 // Cannot create the prototype.
414 return nullptr;
415 }
416
417 proxy = this->NewProxy(groupname, name);
418 if (!proxy)
419 {
420 return nullptr;
421 }
422 proxy->SetLocation(0);
423 proxy->SetPrototype(true);
424 // register the proxy as a prototype.
425 this->RegisterProxy(protype_group.c_str(), name, proxy);
426 proxy->Delete();
427 return proxy;
428}
429
430//---------------------------------------------------------------------------
431void vtkSMSessionProxyManager::RemovePrototype(const char* groupname, const char* proxyname)

Callers 15

GetProxyDocumentationMethod · 0.95
GetProxyHintsMethod · 0.95
GetPropertyHintsMethod · 0.95
GetRepresentationTypeMethod · 0.45
GetFileFormatFiltersMethod · 0.45
GetFormatProxyMethod · 0.45
GetRepresentationTypeMethod · 0.45
GetRepresentationTypeMethod · 0.45
CanDisplayDataMethod · 0.45
GetRepresentationTypeMethod · 0.45
GetSupportedFileTypesMethod · 0.45

Calls 7

GetProxyMethod · 0.95
NewProxyMethod · 0.95
RegisterProxyMethod · 0.95
SetLocationMethod · 0.80
SetPrototypeMethod · 0.80
DeleteMethod · 0.45

Tested by

no test coverage detected