<?xml version="1.0" encoding="utf-8" standalone="yes"?>
<oembed>
  <author_name>perlcodesample</author_name>
  <author_url>https://blog.hatena.ne.jp/perlcodesample/</author_url>
  <blog_title>Perl入門ゼミ</blog_title>
  <blog_url>https://perlcodesample.hatenadiary.jp/</blog_url>
  <categories>
  </categories>
  <description>Perl › オブジェクト指向 › 環境に応じた振る舞い クラスを少しだけ改造してOSに応じて振る舞いを変更するようにしてみましょう。 1. 環境に応じて振る舞いを変えるポリモーフィズム 環境がWindowsだった場合は、FilePath::Windowsクラスのオブジェクトを作成して、環境がそれ以外だったら、FilaPath::Unixクラスのオブジェクトを作成するクラスを書いてみました。 use strict; use warnings; my $file_path = FilePath-&gt;new; my $result = $file_path-&gt;cat_path('a', 'b'); …</description>
  <height>190</height>
  <html>&lt;iframe src=&quot;https://hatenablog-parts.com/embed?url=https%3A%2F%2Fperlcodesample.hatenadiary.jp%2Fentry%2F20090328%2F1237525502&quot; title=&quot;環境に応じたオブジェクトを作成する - Perl入門ゼミ&quot; class=&quot;embed-card embed-blogcard&quot; scrolling=&quot;no&quot; frameborder=&quot;0&quot; style=&quot;display: block; width: 100%; height: 190px; max-width: 500px; margin: 10px 0px;&quot;&gt;&lt;/iframe&gt;</html>
  <image_url></image_url>
  <provider_name>Hatena Blog</provider_name>
  <provider_url>https://hatena.blog</provider_url>
  <published>2009-03-28 14:05:02</published>
  <title>環境に応じたオブジェクトを作成する</title>
  <type>rich</type>
  <url>https://perlcodesample.hatenadiary.jp/entry/20090328/1237525502</url>
  <version>1.0</version>
  <width>100%</width>
</oembed>
