Skip to content

Navigation Menu

Sign in
Appearance settings
    • GitHub Copilot
      Write better code with AI
    • GitHub Models New
      Manage and compare prompts
    • GitHub Advanced Security
      Find and fix vulnerabilities
    • Actions
      Automate any workflow
    • Codespaces
      Instant dev environments
    • Issues
      Plan and track work
    • Code Review
      Manage code changes
    • Discussions
      Collaborate outside of code
    • Code Search
      Find more, search less
    Explore
    • Why GitHub
    • All features
    • Documentation
    • GitHub Skills
    • Blog
  • By company size
    • Enterprises
    • Small and medium teams
    • Startups
    • Nonprofits
    By use case
    • DevSecOps
    • DevOps
    • CI/CD
    • View all use cases
    By industry
    • Healthcare
    • Financial services
    • Manufacturing
    • Government
    • View all industries
    View all solutions
  • Topics
    • AI
    • DevOps
    • Security
    • Software Development
    • View all
    Explore
    • Learning Pathways
    • Events & Webinars
    • Ebooks & Whitepapers
    • Customer Stories
    • Partners
    • Executive Insights
    • GitHub Sponsors
      Fund open source developers
    • The ReadME Project
      GitHub community articles
    Repositories
    • Topics
    • Trending
    • Collections
    • Enterprise platform
      AI-powered developer platform
    Available add-ons
    • GitHub Advanced Security
      Enterprise-grade security features
    • Copilot for business
      Enterprise-grade AI features
    • Premium Support
      Enterprise-grade 24/7 support
  • Pricing

Search code, repositories, users, issues, pull requests...

Clear
    Search syntax tips

    Provide feedback

    We read every piece of feedback, and take your input very seriously.

    Saved searches

    Use saved searches to filter your results more quickly

    To see all available qualifiers, see our documentation.

    Sign in
    Sign up
    Appearance settings
    You signed in with another tab or window. Reload to refresh your session. You signed out in another tab or window. Reload to refresh your session. You switched accounts on another tab or window. Reload to refresh your session. Dismiss alert
    php-func / php-docs-samples Public
    forked from GoogleCloudPlatform/php-docs-samples
    • Notifications You must be signed in to change notification settings
    • Fork 0
    • Star 0
    • Code
    • Pull requests 0
    • Actions
    • Projects 0
    • Security

      Uh oh!

      There was an error while loading. Please reload this page.

    • Insights
    Additional navigation options
    • Code
    • Pull requests
    • Actions
    • Projects
    • Security
    • Insights

    Commit 6996c1b

    Browse filesBrowse files
    bshafferbshaffer
    authored
    chore: update compute to v0.3.0 (GoogleCloudPlatform#1367)
    1 parent 82d0749 commit 6996c1b
    Copy full SHA for 6996c1b

    File tree

    Expand file treeCollapse file tree

    4 files changed

    +11
    -11
    lines changed
    Filter options
    • compute/cloud-client
      • helloworld
        • app.php
        • composer.json
      • instances
        • composer.json
        • src
          • list_instances.php
    Expand file treeCollapse file tree

    4 files changed

    +11
    -11
    lines changed

    ‎compute/cloud-client/helloworld/app.php

    Copy file name to clipboardExpand all lines: compute/cloud-client/helloworld/app.php
    +8-8Lines changed: 8 additions & 8 deletions
    Original file line numberDiff line numberDiff line change
    @@ -62,56 +62,56 @@ function print_message(Message $message)
    6262
    6363

    List Instances

    6464
    65-
    foreach ($instancesClient->list_($projectId, $zoneName) as $instance): ?>
    65+
    foreach ($instancesClient->list($projectId, $zoneName) as $instance): ?>
    6666
     print_message($instance) ?>
    6767
    endforeach ?>
    6868
    6969

    7070

    List Zones

    7171
    72-
    foreach ($zonesClient->list_($projectId) as $zone): ?>
    72+
    foreach ($zonesClient->list($projectId) as $zone): ?>
    7373
     print_message($zone) ?>
    7474
    endforeach ?>
    7575
    7676

    7777

    List Disks

    7878
    79-
    foreach ($disksClient->list_($projectId, $zoneName) as $disk): ?>
    79+
    foreach ($disksClient->list($projectId, $zoneName) as $disk): ?>
    8080
     print_message($disk) ?>
    8181
    endforeach ?>
    8282
    8383

    8484

    List Machine Types

    8585
    86-
    foreach ($machineTypesClient->list_($projectId, $zoneName) as $machineType): ?>
    86+
    foreach ($machineTypesClient->list($projectId, $zoneName) as $machineType): ?>
    8787
     print_message($machineType) ?>
    8888
    endforeach ?>
    8989
    9090

    9191

    List Images

    9292
    93-
    foreach ($imagesClient->list_($projectId) as $image): ?>
    93+
    foreach ($imagesClient->list($projectId) as $image): ?>
    9494
     print_message($image) ?>
    9595
    endforeach ?>
    9696
    9797

    9898

    List Firewalls

    9999
    100-
    foreach ($firewalls = $firewallsClient->list_($projectId) as $firewall): ?>
    100+
    foreach ($firewalls = $firewallsClient->list($projectId) as $firewall): ?>
    101101
     print_message($firewall) ?>
    102102
    endforeach ?>
    103103
    104104

    105105

    List Networks

    106106
    107-
    foreach ($networksClient->list_($projectId) as $network): ?>
    107+
    foreach ($networksClient->list($projectId) as $network): ?>
    108108
     print_message($network) ?>
    109109
    endforeach ?>
    110110
    111111

    112112

    List Operations

    113113
    114-
    foreach ($globalOperationsClient->list_($projectId) as $operation): ?>
    114+
    foreach ($globalOperationsClient->list($projectId) as $operation): ?>
    115115
     print_message($operation) ?>
    116116
    endforeach ?>
    117117

    ‎compute/cloud-client/helloworld/composer.json

    Copy file name to clipboard
    +1-1Lines changed: 1 addition & 1 deletion
    Original file line numberDiff line numberDiff line change
    @@ -1,5 +1,5 @@
    11
    {
    22
    "require": {
    3-
    "google/cloud-compute": "^0.2.0"
    3+
    "google/cloud-compute": "^0.3.0"
    44
    }
    55
    }

    ‎compute/cloud-client/instances/composer.json

    Copy file name to clipboard
    +1-1Lines changed: 1 addition & 1 deletion
    Original file line numberDiff line numberDiff line change
    @@ -1,5 +1,5 @@
    11
    {
    22
    "require": {
    3-
    "google/cloud-compute": "^0.2.0"
    3+
    "google/cloud-compute": "^0.3.0"
    44
    }
    55
    }

    ‎compute/cloud-client/instances/src/list_instances.php

    Copy file name to clipboardExpand all lines: compute/cloud-client/instances/src/list_instances.php
    +1-1Lines changed: 1 addition & 1 deletion
    Original file line numberDiff line numberDiff line change
    @@ -42,7 +42,7 @@ function list_instances(string $projectId, string $zone)
    4242
    {
    4343
    // List the new Compute Engine instance using the InstancesClient
    4444
    $instancesClient = new InstancesClient();
    45-
    $instancesList = $instancesClient->list_($projectId, $zone);
    45+
    $instancesList = $instancesClient->list($projectId, $zone);
    4646

    4747
    printf('Instances for %s (%s)' . PHP_EOL, $projectId, $zone);
    4848
    foreach ($instancesList as $instance) {

    0 commit comments

    Comments
    0 (0)

    Footer

    © 2025 GitHub, Inc.

    Footer navigation

    • Terms
    • Privacy
    • Security
    • Status
    • Docs
    • Contact
    You can’t perform that action at this time.