Export the interface.
165199
public function export()
    {
        if ($this->config == null) {
            throw new LogicException('Context must be set before export the service.');
        }

        if ($this->dispatcher == null) {
            throw new LogicException('Dispatcher must be set before export the service.');
        }

        $this->dispatcher->exportInvoker(
            $this->getInvoker()
        );
    }
182153
def export(self, output=None, **kwargs):
        
        if output is None:
            output = self.DEFAULT_EXPORT
        if output is not None and output in self.export_capacities:
            for cls in getmro(type(self)):
                if hasattr(cls, "EXPORT_TO") and output in cls.EXPORT_TO:
                    return cls.__export__(self, output, **kwargs)
        raise NotImplementedError(
            "Mimetype {} has not been implemented for this resource".format(output or "(No Mimetype)")
        )
700915
def export_osm_file(self):
        """"""
        osm = create_elem('osm', {'generator': self.generator,
                                  'version': self.version})
        osm.extend(obj.toosm() for obj in self)

        return etree.ElementTree(osm)
614668
def export_dashboards(session):
    """"""
    logging.info('Starting export')
    dashboards = session.query(Dashboard)
    dashboard_ids = []
    for dashboard in dashboards:
        dashboard_ids.append(dashboard.id)
    data = Dashboard.export_dashboards(dashboard_ids)
    return data
715445
def export(self, name, columns, points):
        """"""
        if name == self.plugins_to_export()[0] and self.buffer != {}:
            # One complete loop have been done
            logger.debug("Export stats ({}) to RESTful endpoint ({})".format(listkeys(self.buffer),
                                                                             self.client))
            # Export stats
            post(self.client, json=self.buffer, allow_redirects=True)
            # Reset buffer
            self.buffer = {}

        # Add current stat to the buffer
        self.buffer[name] = dict(zip(columns, points))
122784
private void export() {
    if (exportRpcHandler == null || exportRpcHandler.isCompleted()) {
      return;
    }

    ArrayList<Metric> metricsList = Lists.newArrayList();
    for (MetricProducer metricProducer : metricProducerManager.getAllMetricProducer()) {
      metricsList.addAll(metricProducer.getMetrics());
    }

    List<io.opencensus.proto.metrics.v1.Metric> metricProtos = Lists.newArrayList();
    for (Metric metric : metricsList) {
      // TODO(songya): determine if we should make the optimization on not sending already-existed
      // MetricDescriptors.
      // boolean registered = true;
      // if (!registeredDescriptors.contains(metric.getMetricDescriptor())) {
      //   registered = false;
      //   registeredDescriptors.add(metric.getMetricDescriptor());
      // }
      metricProtos.add(MetricsProtoUtils.toMetricProto(metric, null));
    }

    exportRpcHandler.onExport(
        // For now don't include Resource in the following messages, i.e don't allow Resource to
        // mutate after the initial message.
        ExportMetricsServiceRequest.newBuilder().addAllMetrics(metricProtos).build());
  }
173461
def export(self, name, columns, points):
        """"""
        for i in range(len(columns)):
            if not isinstance(points[i], Number):
                continue
            else:
                data = {'host': self.hostname, 'service': name + " " + columns[i], 'metric': points[i]}
                logger.debug(data)
                try:
                    self.client.send(data)
                except Exception as e:
                    logger.error("Cannot export stats to Riemann (%s)" % e)
615504
def export(self, hashVal=None, hashPath=None, tags=None, galleries=None):
        
        hashVal = hashVal or self.hash
        hashPath = hashPath or self.parent / hashVal + self.ext
        
        source = hashPath.replace('\\', '/').replace(ROOT, '')
        galleries = galleries or []
        tags = tags or []

        imagefile = ROOT / source

        if imagefile.ext == '.psd':
            psd = psd_tools.PSDImage.load(imagefile)
            workImage = psd.as_PIL()
        else:
            workImage = pilImage.open(imagefile)
            self.source = source

        if imagefile.ext in ('.tif', '.tiff', '.psd'):
            png = imagefile.parent / '{}.png'.format(imagefile.namebase)
            workImage.save(png)
            workImage = pilImage.open(png)
            imagefile.move(imagefile.replace(self.hash, self.title))
            self.source = png.replace(ROOT, '')

        formats = [
            ('image', FROG_IMAGE_SIZE_CAP),
            ('small', FROG_IMAGE_SMALL_SIZE),
        ]
        for i, n in enumerate(formats):
            if workImage.size[0] > n[1] or workImage.size[1] > n[1]:
                workImage.thumbnail((n[1], n[1]), pilImage.ANTIALIAS)
                setattr(self, n[0], self.source.name.replace(hashVal, '_' * i + hashVal))
                workImage.save(ROOT + getattr(self, n[0]).name)
            else:
                setattr(self, n[0], self.source)

        self.generateThumbnail()

        for gal in galleries:
            g = Gallery.objects.get(pk=int(gal))
            g.images.add(self)

        self.tagArtist()

        for tagName in tags:
            tag = Tag.objects.get_or_create(name=tagName)[0]
            self.tags.add(tag)

        if not self.guid:
            self.guid = self.getGuid().guid
        self.save()
491542
protected void doExport() {
        // Get archive
        final Archive<?> archive = getArchive();
        if (log.isLoggable(Level.FINE)) {
            log.fine("Exporting archive - " + archive.getName());
        }

        // Obtain the root
        final Node rootNode = archive.get(ArchivePaths.root());

        // Recursively process the root children
        for (Node child : rootNode.getChildren()) {
            processNode(child);
        }
    }
64705
public function export()
    {
        $result = array();

        foreach ($this->collection as $name => $property) {
            /* @var $property PropertyDefnitionInterface */
            $result[$name] = $property->getRawType();
        }

        return $result;
    }
585259
def export_all(self):
        
        if self.tab_type == 'fixed':
            self._export_all_fixed()
        if self.tab_type == 'keyword':
            self._export_all_keyword()
438903
def interface(self, context):
        """"""
        self.context = context
        self.callback = self.context.get("callback")
839953
def _plugins_to_export(self):
        """"""
        ret = self.exportable_plugins
        for p in ret:
            if getattr(self.args, 'disable_' + p):
                ret.remove(p)
        return ret
1327473
def export_data(filename_or_fobj, data, mode="w"):
    """"""

    if filename_or_fobj is None:
        return data

    _, fobj = get_filename_and_fobj(filename_or_fobj, mode=mode)
    source = Source.from_file(filename_or_fobj, mode=mode, plugin_name=None)
    source.fobj.write(data)
    source.fobj.flush()
    return source.fobj
1002431
protected function export()
    {
        $filesystem = new Filesystem();
        $handle = fopen($this->config['path'] . $this->prefix, "w");

        $checkPermissions = true;
        if (PHP_SAPI == 'cli') {
            $checkPermissions = false;
        }

        if (!$this->export->Init(
            $handle,
            $this->config["id"],
            false,
            true,
            $this->session["work_dir"],
            $this->session["file_dir"],
            $checkPermissions
        )
        ) {
            throw new ExportException('Failed to initialize export');
        }

        $this->export->DoNotDownloadCloudFiles();
        $this->export->StartExport();

        $this->export->StartExportMetadata();
        $this->export->ExportProperties($this->session["property_map"]);
        $this->export->ExportSections(
            $this->session["section_map"],
            time(),
            $this->config['interval'],
            $this->config["sections"],
            $this->session["property_map"]
        );
        $this->export->EndExportMetadata();

        $this->export->StartExportCatalog();
        $this->export->ExportElements(
            $this->session["property_map"],
            $this->session["section_map"],
            time(),
            $this->config['interval'],
            0,
            $this->config["elements"]
        );
        $this->export->EndExportCatalog();

        $this->export->ExportProductSets();
        $this->export->EndExport();

        fclose($handle);
        $filesystem->remove($this->config['path']);
        $filesystem->rename($this->config['path'] . $this->prefix, $this->config['path'], true);
    }
1285187
public static String exportTypeSystem() {
      Resource out = new StringResource();
      try {
         exportTypeSystem(out);
         return out.readToString().trim();
      } catch (IOException e) {
         throw Throwables.propagate(e);
      }
   }
433314
public function export()
    {
        $path = $this->module->dataPath;
        FileHelper::createDirectory($path, $this->module->dirMode);

        $summary = $this->collectSummary();
        $dataFile = "$path/{$this->tag}.data";
        $data = [];
        $exceptions = [];
        foreach ($this->module->panels as $id => $panel) {
            try {
                $data[$id] = serialize($panel->save());
            } catch (\Exception $exception) {
                $exceptions[$id] = new FlattenException($exception);
            }
        }
        $data['summary'] = $summary;
        $data['exceptions'] = $exceptions;

        file_put_contents($dataFile, serialize($data));
        if ($this->module->fileMode !== null) {
            @chmod($dataFile, $this->module->fileMode);
        }

        $indexFile = "$path/index.data";
        $this->updateIndexFile($indexFile, $summary);
    }