What do you want to save?
Add Code snippet
New code examples
-
PHP 2021-09-27 16:36:02
drupal 9 custom blocks dependency injection
/** * @file * Contains \Drupal\mymod\Plugin\Block\MyModMyStoreProductsStatusBlock */ namespace Drupal\mymod\Plugin\Block; use Drupal\Core\Block\BlockBase; use Drupal\Core\Plugin\ContainerFactoryPluginInterface; use Drupal\mymod\StoreService; use Symf... Add solution -
Shell/Bash 2021-09-24 13:57:03
cisco router command create subinterface as dot1q
!-- Set the privileged mode !-- and Telnet password on the switch. switch#configure terminal Enter configuration commands, one per line. End with CNTL/Z. switch(config)#hostname 3512xl 3512xl(config)#enable password mysecret 3512xl(config)#line vty 0 ... Add solution -
TypeScript 2021-09-23 05:40:03
can interface have objects in java
No, you can never instantiate an interface in java. You can, however, refer to an object that implements an interface by the type of the interface. interface Animal{ void eat(); } You cannot do this “Animal animal = new Animal();” Bcoz in ... Add solution -
Python 2021-09-21 17:49:03
how to make text change lines pygame
import pygame pygame.init() SIZE = WIDTH, HEIGHT = (1024, 720) FPS = 30 screen = pygame.display.set_mode(SIZE, pygame.RESIZABLE) clock = pygame.time.Clock() def blit_text(surface, text, pos, font, color=pygame.Color('black')): words = [word.split(... Add solution -
Python 2021-09-21 02:54:03
how to make a poker game in python
#poker print("poker username: ") name = input("") print("age: ") age = input("") #continue input("\n\nPress the [enter key]") #make random cards by importing import random #player cards print("your... Add solution -
TypeScript 2021-09-20 13:02:03
unity rich text options
<!-- These are the richtext options unity supports --> <b>bold</b> <!-- Renders the text in boldface. --> <i>italics</i> <!-- Renders the text in italics. --> <size=50>size</size> <!-- Sets the siz... Add solution -
Python 2021-09-19 13:25:02
python opengl freetype
import freetype as ft # change the filename if necessary face = ft.Face("Vera.ttf") # the size is specified in 1/64 pixel face.set_char_size(48*64) # initialize Stroker stroker = ft.Stroker() # change the outline size if necessary stroker.set(1... Add solution -
Java 2021-09-19 08:46:03
abstraction in java
bstraction: Hiding the implementation details, concentrating on essentials things, without worrying about the details ■ In java, abstraction is achieved via abstract class or interface ■ Abstraction cannot exist without inheritance 3.1. Abstract cla... Add solution