Skip to main content
Drupal API
User account menu
  • Log in

Breadcrumb

  1. Drupal Core 11.1.x
  2. FileOptions.php

function FileOptions::getGoPackage

Sets the Go package where structs generated from this .proto will be placed. If omitted, the Go package will be derived from the following:

  • The basename of the package import path, if provided.
  • Otherwise, the package statement in the .proto file, if present.
  • Otherwise, the basename of the .proto file, without extension.

Generated from protobuf field <code>optional string go_package = 11;</code>

Return value

string

File

vendor/google/protobuf/src/Google/Protobuf/Internal/FileOptions.php, line 541

Class

FileOptions
Generated from protobuf message <code>google.protobuf.FileOptions</code>

Namespace

Google\Protobuf\Internal

Code

public function getGoPackage() {
    return isset($this->go_package) ? $this->go_package : '';
}

API Navigation

  • Drupal Core 11.1.x
  • Topics
  • Classes
  • Functions
  • Constants
  • Globals
  • Files
  • Namespaces
  • Deprecated
  • Services
RSS feed
Powered by Drupal