Sha256: 41610cf7c7c5fc106052fac9f8ef21e5f52261df20682aa9a2590f09d6a969cd

Contents?: true

Size: 729 Bytes

Versions: 3

Compression:

Stored size: 729 Bytes

Contents

require 'moblues/generator/objc/base'

module Moblues
  module Generator
    module Objc
      class Machine < Base
        def generate(output_dir, entity)
          write_header(output_dir, entity)
          write_implementation(output_dir, entity)
        end

        private
        def format_name(entity, extension)
          "_#{entity.name}.#{extension}"
        end

        def capitalized_name(relationship)
          relationship.name.sub(/^./) { |first_character| first_character.upcase }
        end

        def header_template
          file_template('machine_header.h')
        end

        def implementation_template
          file_template('machine_implementation.m')
        end
      end
    end
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
moblues-0.4.0 lib/moblues/generator/objc/machine.rb
moblues-0.3.0 lib/moblues/generator/objc/machine.rb
moblues-0.2.0 lib/moblues/generator/objc/machine.rb