{"id":19131144,"url":"https://github.com/pjsalter/pawsome-profiles","last_synced_at":"2026-06-08T10:30:16.750Z","repository":{"id":204295411,"uuid":"711496135","full_name":"PJSalter/Pawsome-Profiles","owner":"PJSalter","description":"🐶 Pawsome-Profiles: A C++ project demonstrating object-oriented programming principles through a pet management system with base class Pet and derived class Dog. 🐾","archived":false,"fork":false,"pushed_at":"2023-10-29T14:42:09.000Z","size":6,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"main","last_synced_at":"2025-01-03T11:21:58.545Z","etag":null,"topics":["cpp","cpp20","object-oriented-programming"],"latest_commit_sha":null,"homepage":"","language":"C++","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/PJSalter.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null}},"created_at":"2023-10-29T12:58:34.000Z","updated_at":"2023-10-30T22:52:51.000Z","dependencies_parsed_at":null,"dependency_job_id":"d73c8312-16df-42ee-839d-da17d73eddc6","html_url":"https://github.com/PJSalter/Pawsome-Profiles","commit_stats":null,"previous_names":["pjsalter/pawsome-profiles"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PJSalter%2FPawsome-Profiles","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PJSalter%2FPawsome-Profiles/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PJSalter%2FPawsome-Profiles/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/PJSalter%2FPawsome-Profiles/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/PJSalter","download_url":"https://codeload.github.com/PJSalter/Pawsome-Profiles/tar.gz/refs/heads/main","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":240206995,"owners_count":19765041,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["cpp","cpp20","object-oriented-programming"],"created_at":"2024-11-09T06:14:18.359Z","updated_at":"2026-06-08T10:30:16.656Z","avatar_url":"https://github.com/PJSalter.png","language":"C++","funding_links":[],"categories":[],"sub_categories":[],"readme":"# Pawsome-Profiles\n\n## Table of Contents\n\n- [Introduction](#introduction)\n- [Project Structure](#project-structure)\n- [Usage](#usage)\n- [Sample Input and Output](#sample-input-and-output)\n- [Class Details](#class-details)\n- [Conclusion](#conclusion)\n\n## Introduction\n\n**Pawsome-Profiles** is a C++ project that demonstrates the use of derived classes in object-oriented programming. It focuses on managing pet information, with a base class named `Pet` and a derived class called `Dog`. The base class stores common attributes such as the pet's name and age, while the derived class extends the functionality to include the dog's breed. This project is designed to showcase how inheritance and encapsulation work in C++.\n\n## Project Structure\n\nThe project consists of the following files:\n\n- **main.cpp**: Contains the main function where pets are created, their information is set, and details are printed.\n- **Pet.h**: Header file for the base class `Pet`.\n- **Dog.h**: Header file for the derived class `Dog`.\n- **Pet.cpp**: Implementation file for the `Pet` class.\n- **Dog.cpp**: Implementation file for the `Dog` class.\n\n## Usage\n\nTo use the \"Pawsome-Profiles\" project, follow these steps:\n\n1. Build the project using a C++ compiler. For example:\n\n   ```bash\n   g++ main.cpp Pet.cpp Dog.cpp -o pawsome_profiles\n   ```\n\n2. Run the compiled executable:\n\n   ```bash\n   ./pawsome_profiles\n   ```\n\n3. You will be prompted to enter pet information. For a generic pet, enter the name and age. For a dog pet, also enter the breed.\n\n4. The program will display the pet's information, and for a dog, it will show the breed as well.\n\n## Sample Input and Output\n\nFor instance, if you provide the following input:\n\n   ```bash\n   Dobby\n   2\n   Kreacher\n   3\n   German Schnauzer\n   ```\n\nThe program will produce the following output:\n\n```\nPet Information:\n   Name: Dobby\n   Age: 2\nPet Information:\n   Name: Kreacher\n   Age: 3\n   Breed: German Schnauzer\n```\n\n## Class Details\n\n### Pet Class\n\nThe `Pet` class is the base class and has the following attributes and methods:\n\n  - ###### Attributes:\n\n- `petName` (protected): Stores the pet's name.\n- `petAge` (protected): Stores the pet's age.\n\n  - ###### Methods:\n\n- `SetName(string userName)`: Sets the pet's name.\n- `GetName()`: Retrieves the pet's name.\n- `SetAge(int userAge)`: Sets the pet's age.\n- `GetAge()`: Retrieves the pet's age.\n- `PrintInfo()`: Prints the pet's name and age.\n\n### Dog Class\n\nThe `Dog` class is a derived class of `Pet` and has the following additional attributes and methods:\n\n   - ###### Attributes:\n\n`dogBreed` (private): Stores the dog's breed.\n\n   - ###### Methods:\n\n- `SetBreed(string userBreed)`: Sets the dog's breed.\n- `GetBreed()`: Retrieves the dog's breed.\n\n  ## Conclusion\n\n  \"Pawsome-Profiles\" is a simple yet illustrative project that demonstrates the concepts of inheritance and encapsulation in object-oriented programming using C++. It provides a hands-on example of how to create, manage, and print pet information for both generic pets and dogs with breeds.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpjsalter%2Fpawsome-profiles","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fpjsalter%2Fpawsome-profiles","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fpjsalter%2Fpawsome-profiles/lists"}