?? ???? Amazon?? ? ?? ????? ????. ???? ??? ???? Medium?? ?? ????? ?? ?? ???. ?? ???? ??? ??????! ??? ??? ? ??? ????!
Java? ?? ?? ?? ? ??? ??? ??? ??????? ???? ?? ??? ??? Java ????? ??? ?? ??? ? ????. ? ????? ??? ??? ?? 5?? ?? ?????? ??? ???? ?? ??? ?? ??? ???? ???? ?? ??? ?????.
??? ?????? ASM? ??? ???? ??????. ??? ?? API? ??? ??? ?? ??? ??? ?????? ?????.
?? ??? ??? ???? ASM ?? ??? ????.
ClassWriter cw = new ClassWriter(ClassWriter.COMPUTE_FRAMES); cw.visit(V1_8, ACC_PUBLIC, "DynamicClass", null, "java/lang/Object", null); // Constructor MethodVisitor mv = cw.visitMethod(ACC_PUBLIC, "<init>", "()V", null, null); mv.visitCode(); mv.visitVarInsn(ALOAD, 0); mv.visitMethodInsn(INVOKESPECIAL, "java/lang/Object", "<init>", "()V", false); mv.visitInsn(RETURN); mv.visitMaxs(1, 1); mv.visitEnd(); // Method: public void sayHello() mv = cw.visitMethod(ACC_PUBLIC, "sayHello", "()V", null, null); mv.visitCode(); mv.visitFieldInsn(GETSTATIC, "java/lang/System", "out", "Ljava/io/PrintStream;"); mv.visitLdcInsn("Hello, Dynamic World!"); mv.visitMethodInsn(INVOKEVIRTUAL, "java/io/PrintStream", "println", "(Ljava/lang/String;)V", false); mv.visitInsn(RETURN); mv.visitMaxs(2, 1); mv.visitEnd(); cw.visitEnd(); byte[] bytes = cw.toByteArray();
???? "sayHello" ???? ???? ???? ???? ?????? ? ?? "DynamicClass"? ?????.
Javassist? Java ?? ?? ???? ???? ??? ??? ????? ? ?? ??? API? ?????.
? Javassist ?? ?? ??? ??? ?????.
ClassPool pool = ClassPool.getDefault(); CtClass cc = pool.makeClass("DynamicClass"); // Add a constructor CtConstructor constructor = new CtConstructor(new CtClass[]{}, cc); constructor.setBody("{}"); cc.addConstructor(constructor); // Add a method CtMethod method = new CtMethod(CtClass.voidType, "sayHello", new CtClass[]{}, cc); method.setBody("System.out.println(\"Hello, Dynamic World!\");"); cc.addMethod(method); // Generate the class Class<?> clazz = cc.toClass();
???? ??? ?? ??? ??? ??? ??????.
?? ?????? ByteBuddy? ???? ??? ??? ?? ??? API? ?????. ??? ??? ?? ???? ?? ???? ???? ??? ?????.
??? ByteBuddy ????.
Class<?> dynamicType = new ByteBuddy() .subclass(Object.class) .name("DynamicClass") .defineMethod("sayHello", void.class, Modifier.PUBLIC) .intercept(FixedValue.value("Hello, Dynamic World!")) .make() .load(getClass().getClassLoader()) .getLoaded(); Object instance = dynamicType.getDeclaredConstructor().newInstance(); Method method = dynamicType.getMethod("sayHello"); System.out.println(method.invoke(instance));
???? ??? API? ??? ??? ??????.
Cglib? ?? ??? ? ??? ??? ?? ???? ?? Spring? ?? AOP ?????? ?????.
? Cglib ??? ?? ???? ?????.
public interface PersonService { String getName(); } public class PersonServiceImpl implements PersonService { public String getName() { return "John Doe"; } } // Creating a dynamic proxy Enhancer enhancer = new Enhancer(); enhancer.setSuperclass(PersonServiceImpl.class); enhancer.setCallback(new MethodInterceptor() { public Object intercept(Object obj, Method method, Object[] args, MethodProxy proxy) throws Throwable { System.out.println("Before method call : " + method.getName()); Object result = proxy.invokeSuper(obj, args); System.out.println("After method call : " + method.getName()); return result; } }); PersonService proxy = (PersonService) enhancer.create(); System.out.println(proxy.getName());
??? ?? ?? ??? ?????.
Byte Buddy Agent? ByteBuddy? ???? ? ??? ? ?? ??? ??? ??? ??? ??? ? ???? ?????. ?????? ?? ?? Java ????? ???? ???? ??? ????.
? ???? Byte Buddy Agent? ??? ??? ??? ???? ?????.
public class MyClass { public void originalMethod() { System.out.println("Original method"); } } // Somewhere in your application Instrumentation instrumentation = ByteBuddyAgent.install(); new ByteBuddy() .redefine(MyClass.class) .method(named("originalMethod")) .intercept(FixedValue.value("Redefined method")) .make() .load(MyClass.class.getClassLoader(), ClassReloadingStrategy.fromInstalledAgent()); MyClass instance = new MyClass(); instance.originalMethod(); // Prints "Redefined method"
?? ??? ??? ???? ?????.
????? ??? ???? ???, ?? ?? ??, ??? ???? ?? ????. ASM? ?? ??? ??? ??? ??? ???? Javassist ?? ByteBuddy? ? ??? ?? ??? ? ?????. Cglib? ?? ??? ??? ???? Byte Buddy Agent? ??? ??? ???? ?????.
????? ??? ????? ??? ??? ? ?? ?? ??? ??? ?? ???? ???? ???. ??? ???? ?? ??? ? ?? ???. ??? ?? ??? ?????.
????? ??? ?????? ???? ?? ???? ???? Java ??????? ???? ? ??? ???. ??? ??????? ?? ??? ????? ???? ????? ???? ???.
101?
101 Books? ?? Aarav Joshi? ?? ??? AI ?? ??????. ??? AI ?? ?? ??? ?? ??? ??????. ?? ??? ??? $4?? ???? ?? ??? ??? ??? ???? ? ????.
Amazon?? Golang Clean Code ?? ?????.
???? ? ??? ?????. ? ?? ?? ??? Aarav Joshi? ???? ??? ??? ???? ?? ??? ????!
??? ???
?? ???? ????:
???? ??? | ??? ?? ???? | ?? ?? ??? | ????? | ??? ??? | ????? ???? | ???? | ??? ??? | JS ??
Medium? ????
?? ??? ???? | Epochs & Echoes World | ??????? | ???? ???? ?? | ??? ??? ?? | ?? ????
? ??? ?? ?? ??? ?? ??? Java ????? ?? ?????? ?? ?????. ??? ??? PHP ??? ????? ?? ?? ??? ?????!

? AI ??

Undress AI Tool
??? ???? ??

Undresser.AI Undress
???? ?? ??? ??? ?? AI ?? ?

AI Clothes Remover
???? ?? ???? ??? AI ?????.

Clothoff.io
AI ? ???

Video Face Swap
??? ??? AI ?? ?? ??? ???? ?? ???? ??? ?? ????!

?? ??

??? ??

???++7.3.1
???? ?? ?? ?? ???

SublimeText3 ??? ??
??? ??, ???? ?? ????.

???? 13.0.1 ???
??? PHP ?? ?? ??

???? CS6
??? ? ?? ??

SublimeText3 Mac ??
? ??? ?? ?? ?????(SublimeText3)

??? ??











?? ?? ?? ??? ??? ?? ??? ??, ? ? ?? ? ??? ?????. 1. ??? ?? ???? ?? ???? ???-????, ? ??? ??? ??? ? ????, Hashmap? ???-??? ?? ??? ??? ???? ????. 2. NULL ? ?? ???? HashMap? ??? NULL ?? ?? ? ?? ???? ?? HashTable? NULL ?? ?? ???? ??? NullPointerException? ?????. 3. ????? ??? ????? ?? ??? ?? ?? ? ????? HashTable? ? ??? ?? ?? ??? ????. ?? ConcurrenTashMap? ???? ?? ????.

Java? ?? ??? ??? ?? ??? ??? ?? ??? ??? ?? ??? ?? ?? ??? ???? ??? ?? ???? ?????. 1. ??? ???? ??? ?? ?? ? ???? ?? ??? ???? ?? ?? ??? ? ????. 2. ???? ?? ??? ???? ??? ?? ???? ?? ?? ??? ???????. 3. ?? ???? ?? ?? ?? ? ???? ???? ?? NULL ?? ??? ? ????. 4. ?? ???? ??? ?? ?? ? ??? ?????? ?? ??? ??? ?? ?? ??? ????? ??? ??? ??? ??????? ?? ???? ??????.

staticmethodsininterfaceswereIntRectionSelffacesswithinteffaceswithinteffaceswithintintinjava8toallowutilityFunctionswithinterfaceitswithinteffaceswithinterfaceffaces

JIT ????? ??? ???, ??? ?? ? ???, ?? ?? ? ???? ? ? ?? ?? ??? ? ?? ??? ?? ??? ??????. 1. ??? ???? ?? ?? ??? ??? ?? ?? ???? ??? ?? ?????. 2. ??? ?? ? ??? ?? ?? ? ??? ???? ?? ?? ???; 3. ?? ??? ??? ?? ??? ???? ???? ???? ? ?? ?? ??? ?????. 4. ?? ??? ?? ??? ??? ???? ???? ?? ? ??? ???? ?? ??? ?????.

???? ??? ??? Java?? ??? ?? ???? ??? ?? ? ? ??? ??? ???? ? ?????. ?? ???? ??? ??, ??? ?? ??? ?? ?? ??? ??? ????? ???? ????? ?????. ?? ??? ??? ??, ????? ? ??? ????, ?? ??? ??? ?????? ? ?? ? ?? ?????.

injava, thefinalkeywordpreventsavariable'svalue'svalueffrombeingchangedafterassignment, butitsbehaviordiffersforprimitivesandobjectreences.forprimitivevariables, asinfinalintmax_speed = 100; wherereassoncesanerror.forobjectref

??? ??? ?? ?? ??? ????? ? ???? ????? ???? ?? ???? ?? ???? ?????. ?? ??? ??? ????. ?? ?? ?? ??? ???? ???? ?? ?? ??? ??? ?? ?? ??? ??? ?????. ?? ??? ??? ????. ?? ??? ?? ??? ?? ?? ??? ?? ?? ??? ???? NewClass ()? ??? ?? ???? ????. ?? ??? ?? ??? ???? ?? ??? ?? ? ? ??? ?? ?? ??? ????? ????? ?????. ?? ??, ?? ?????? ?????, ??? ? ?? ????? ??? ?? ?????. ???? ?? ?? ??? ???? ?? ???? ?? ? ??? ???? ?? ??? ?? ?????? ?????. ???? ???? ??? ??, ?? ?? ? ?? ??? ????, ?? ?? ???? ?????.

??? ? ?? ??? ???? : ????? ?? ?. 1. int? ???? ???? ?? ?? ?? ? ??? ???? ?????. 2. ?? ? ???? (int) myDouble ??? ?? ?? ??? ?????. ?? ??? ??? ?? ??? ?? ??, ?? ?? ?? ???? ?? ??? ?? ???? ?? ?????. ???? ? ??? ??? ????. ?? ??? ??? ??? ??? ??? ?? ??? ??? ? ??? ?? ???? ??? ??? ??? ??? ? ??? ?? ??? ?? ??? ?? ?? ? ? ????. ?? ?? ??? ?? ??? ??? ??? ??? ? ??????.
