Learning Perl Objects, References amp;amp; Modules [Electronic resources] نسخه متنی

اینجــــا یک کتابخانه دیجیتالی است

با بیش از 100000 منبع الکترونیکی رایگان به زبان فارسی ، عربی و انگلیسی

Learning Perl Objects, References amp;amp; Modules [Electronic resources] - نسخه متنی

Randal L. Schwartz

| نمايش فراداده ، افزودن یک نقد و بررسی
افزودن به کتابخانه شخصی
ارسال به دوستان
جستجو در متن کتاب
بیشتر
تنظیمات قلم

فونت

اندازه قلم

+ - پیش فرض

حالت نمایش

روز نیمروز شب
جستجو در لغت نامه
بیشتر
لیست موضوعات
توضیحات
افزودن یادداشت جدید














12.4 A More Typical Object-Oriented Module: Math::BigInt


So as
not to get dismayed about how
"un-OO" the
File::Spec module might be, let's
look at yet another core module, Math::BigInt:

use Math::BigInt;
my $value = Math::BigInt->new(2); # start with 2
$value->bpow(1000); # take 2**1000
print $value->bstr( ), "\n"; # print it out

Here, nothing is imported. The entire
interface calls class methods such as new against
the class name to create instances, and then calls instance methods
against those instances.



/ 199