Home Accessibility Courses Twitter The Mouth Facebook Resources Site Map About Us Contact
Introspecion in Perl 6

Perl 6 provides introspection - that's the ability for its object to be able to report on methods, attributes and inheritances.

And if you run Perl6 without an input file, it goes into a read - interpret - run cycle with each line you type in, rather like Python, Ruby and Tcl do. So we can experiment easily with that introspection.

  WomanWithCat:jan16 grahamellis$ perl6
  > "...".^methods
  (BUILD Int Num chomp chop pred succ simplematch match ords samecase
  samemark samespace word-by-word trim-leading trim-trailing trim
  encode NFC NFD NFKC NFKD wordcase trans indent codes chars uc
  lc tc fc tclc flip ord WHY WHICH Bool Str Stringy DUMP ACCEPTS
  Numeric gist perl comb subst-mutate subst lines split words)
  >


  WomanWithCat:jan16 grahamellis$ perl6
  > my $v = 4;
  4
  > $v.^methods
  (Int Num Rat FatRat abs Bridge chr sqrt base polymod expmod is-prime
  floor ceiling round lsb msb narrow Range sign sin tan cotan acosech
  conj atan2 cosec pred asec acotan cosh acos acosec sech unpolar
  log10 atanh log exp acosh truncate sinh tanh acotanh Real sec
  isNaN succ rand asin cos cis cosech asech roots Complex cotanh
  asinh atan WHICH new perl Bool Str gist ACCEPTS DUMP Numeric)
  >

(written 2016-01-02)

 
Associated topics are indexed as below, or enter http://melksh.am/nnnn for individual articles
P600 - Perl 6
  [4620] Perl 6 - a Practical Extraction and Reporting example! - (2016-01-11)
  [4611] Hungarian, Camel, Snake and Kebab - variable naming conventions - (2016-01-03)
  [4610] Sorting by key or by comparator - Perl 6 - (2016-01-03)
  [4609] Mapping an array / list without a loop - how to do it in Perl 6 - (2016-01-03)
  [4607] Classes and object - first steps in Perl 6 - (2016-01-02)
  [4606] Using Perl 6 to analyse and report on data - (2016-01-02)
  [4605] Hello World - in Perl 6 - (2016-01-02)
  [4604] Perl - version 6 - official version launched at Christmas - (2016-01-02)
  [2816] Intelligent Matching in Perl - (2010-06-18)
  [582] DWIM and AWWO - (2006-01-30)

P301 - Variables in Perl
  [4398] Accessing variables across subroutine boundaries - Perl, Python, Java and Tcl - (2015-01-18)
  [3430] Sigils - the characters on the start of variable names in Perl, Ruby and Fortran - (2011-09-10)
  [3059] Object Orientation in an hour and other Perl Lectures - (2010-11-18)
  [2972] Some more advanced Perl examples from a recent course - (2010-09-27)
  [2877] Further more advanced Perl examples - (2010-07-19)
  [2374] Lead characters on Perl variable names - (2009-08-24)
  [2241] Perl references - $$var and \$var notations - (2009-06-15)
  [1946] Variable Types in Perl - (2008-12-15)
  [1581] What is an lvalue? (Perl, C) - (2008-03-18)
  [975] Answering ALL the delegate's Perl questions - (2006-12-09)


Back to
Classes and object - first steps in Perl 6
Previous and next
or
Horse's mouth home
Forward to
Mapping an array / list without a loop - how to do it in Perl 6
Some other Articles
TransWilts - robust these days - no longer the first service to be cancelled
Introspecion in Perl 6
Happy New Year. Our customers are our ambassadors
4749 posts, page by page
Link to page ... 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, 35, 36, 37, 38, 39, 40, 41, 42, 43, 44, 45, 46, 47, 48, 49, 50, 51, 52, 53, 54, 55, 56, 57, 58, 59, 60, 61, 62, 63, 64, 65, 66, 67, 68, 69, 70, 71, 72, 73, 74, 75, 76, 77, 78, 79, 80, 81, 82, 83, 84, 85, 86, 87, 88, 89, 90, 91, 92, 93, 94, 95 at 50 posts per page


This is a page archived from The Horse's Mouth at http://www.wellho.net/horse/ - the diary and writings of Graham Ellis. Every attempt was made to provide current information at the time the page was written, but things do move forward in our business - new software releases, price changes, new techniques. Please check back via our main site for current courses, prices, versions, etc - any mention of a price in "The Horse's Mouth" cannot be taken as an offer to supply at that price.

Link to Ezine home page (for reading).
Link to Blogging home page (to add comments).

You can Add a comment or ranking to this page

© WELL HOUSE CONSULTANTS LTD., 2017: 404 The Spa • Melksham, Wiltshire • United Kingdom • SN12 6QL
PH: 01144 1225 708225 • EMAIL: info@wellho.net • WEB: http://www.wellho.net • SKYPE: wellho

PAGE: http://www.wellho.net/mouth/4608_Int ... erl-6.html • PAGE BUILT: Sat May 27 16:49:10 2017 • BUILD SYSTEM: WomanWithCat