Supported Versions: PHP 4, PHP 5, PHP 7, PHP 8
Return all the keys or a subset of the keys of an array
<?php array_keys(array $array): array
<?php     public function keys(): array

    {

        return array_keys($this->classifications);

    }



    public function uniqueTypes(): TypeClassificationCollection
<?php     public function test_income_classification_categories_label()

    {

        $expected = array_keys($this->incomeClassifications['1.1']);

        $actual_1 = InvoiceType::TYPE_1_1->incomeClassifications()->toKeyLabel();

        $actual_2 = IncomeClassificationType::for(InvoiceType::TYPE_1_1)->toKeyLabel();

        $actual_3 = Classifications::incomeClassifications(InvoiceType::TYPE_1_1)->toKeyLabel();
<?php     public function test_expense_classification_categories_label()

    {

        $expected = array_keys($this->expenseClassifications['1.1']);

        $actual_1 = InvoiceType::TYPE_1_1->expenseClassifications()->toKeyLabel();

        $actual_2 = ExpenseClassificationType::for(InvoiceType::TYPE_1_1)->toKeyLabel();

        $actual_3 = Classifications::expenseClassifications(InvoiceType::TYPE_1_1)->toKeyLabel();
<?php         $attributes = $invoiceHeader->attributes();




        $keys = array_keys($attributes);

        shuffle($keys);
<?php         $invoiceHeader->setAttributes(array_merge(array_flip($keys), $attributes));




        $this->assertSame($invoiceHeader->getExpectedOrder(), array_keys($invoiceHeader->sortedAttributes()));

    }



    public function test_transmission_failure_is_sorted()
<?php         $invoice->setTransmissionFailure(TransmissionFailure::ERP_CONNECTION_FAILURE);



        $expectedTransmissionFailureIndex = array_search('transmissionFailure', $invoice->getExpectedOrder());

        $actualTransmissionFailureIndex = array_search('transmissionFailure', array_keys($invoice->sortedAttributes()));

        

        $this->assertNotFalse($expectedTransmissionFailureIndex);

        $this->assertNotFalse($actualTransmissionFailureIndex);