{
    "mode": "perldoc",
    "parameter": "BSON::Int32",
    "section": "",
    "url": "https://www.chedong.com/phpMan.php/perldoc/BSON%3A%3AInt32/json",
    "generated": "2026-07-05T05:44:15Z",
    "synopsis": "use BSON::Types ':all';\nbsonint32( $number );",
    "sections": {
        "NAME": {
            "content": "BSON::Int32 - BSON type wrapper for Int32\n",
            "subsections": []
        },
        "VERSION": {
            "content": "version v1.12.2\n",
            "subsections": []
        },
        "SYNOPSIS": {
            "content": "use BSON::Types ':all';\n\nbsonint32( $number );\n",
            "subsections": []
        },
        "DESCRIPTION": {
            "content": "This module provides a BSON type wrapper for a numeric value that would be represented in BSON\nas a 32-bit integer.\n\nIf the value won't fit in a 32-bit integer, an error will be thrown.\n",
            "subsections": []
        },
        "ATTRIBUTES": {
            "content": "value\nA numeric scalar. It will be coerced to an integer. The default is 0.\n",
            "subsections": []
        },
        "METHODS": {
            "content": "TOJSON\nReturns the value as an integer.\n\nIf the \"BSONEXTJSON\" environment variable is true and the \"BSONEXTJSONRELAXED\" environment\nvariable is false, returns a hashref compatible with MongoDB's extended JSON\n<https://github.com/mongodb/specifications/blob/master/source/extended-json.rst> format, which\nrepresents it as a document as follows:\n\n{\"$numberInt\" : \"42\"}\n",
            "subsections": []
        },
        "OVERLOADING": {
            "content": "The numification operator, \"0+\" is overloaded to return the \"value\", the full \"minimal set\" of\noverloaded operations is provided (per overload documentation) and fallback overloading is\nenabled.\n",
            "subsections": []
        },
        "AUTHORS": {
            "content": "*   David Golden <david@mongodb.com>\n\n*   Stefan G. <minimalist@lavabit.com>\n",
            "subsections": []
        },
        "COPYRIGHT AND LICENSE": {
            "content": "This software is Copyright (c) 2020 by Stefan G. and MongoDB, Inc.\n\nThis is free software, licensed under:\n\nThe Apache License, Version 2.0, January 2004\n",
            "subsections": []
        }
    },
    "summary": "BSON::Int32 - BSON type wrapper for Int32",
    "flags": [],
    "examples": [],
    "see_also": []
}